Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Run PHP client side [closed]

Tags:

php

Is it possible to launch a PHP script, client side, using an HTML web page?

If not, is there a way to embed the PHP into the HTML so it can run client side?

like image 771
user2127874 Avatar asked Mar 08 '13 03:03

user2127874


2 Answers

I think what you want is JavaScript. PHP is meant for server-side and JavaScript is meant for client side, among other things.

like image 53
blaedj Avatar answered Sep 30 '22 05:09

blaedj


No. PHP cannot be run in browser. Learn JavaScript, alternatively CoffeScript if you don't like JavaScript's syntax.

like image 23
Daniil Ryzhkov Avatar answered Sep 30 '22 06:09

Daniil Ryzhkov