How to run php through javascript

Status
Not open for further replies.

QwertyManiac

Commander in Chief
Eh?

PHP scripts run on the server (Pre-serve). JS runs on the client(Post-serve). You can't do that. Just re-think your approach, whatever it is that you're trying to do, instead of ugly-thinking your way through.

But what you can do is, call an alternative .php page with some arguments via JS. You can not, in any way, run PHP code in-line within JS.
 
Status
Not open for further replies.
Top Bottom