askfoki.blogg.se

Php runner on web
Php runner on web










We should note here that the latter part isn’t something you get to decide – the user’s browser decides whether it will default to open the ‘window’ either as a new tab or as a new window.

#Php runner on web how to

But what I (and many others apparently) were chasing was how to have a PHPRunner Add page accept data, and in an after_record_added event, have a PHP process run and generate a PDF dynamically based on data just added, then once the server processing is complete, and the PDF is available on the server, have it automatically open the PDF for the user. If you were building a web page in HTML, there are plenty of ways to set a hyperlink and tie an event/listener to it so that your user can click the href and you can control how the link opens a new target. But it’s not! All of which means that PHP cannot make the browser do anything directly.

php runner on web

Especially as we have PHP script events surrounding all our data interactions in PHPRunner – it “feels” like PHP code is executing on the client. This is more a PHP tip, than a PHPRunner tip, but I needed it recently in a PHPRunner application so maybe you do to?įirst of all, even though we use PHP for web page interactions, it’s very easy to forget that PHP is a server-side scripting language. Let’s start with why it was a problem and then get to the very quick one-liner solution. Really? Something that I had expected to be super-trivial ended up taking me hours of googling stack overflow just to figure out how to approach this.

php runner on web

The task: in a PHPRunner event, launch a PDF in a new tab/window.










Php runner on web