Is it possible to embedd php in javascript?

A

Anonymous

Guest
Hi!

I would like to know if it is possible in some way to embedd php in javascript. I tryed the code below but it didn't work. Would be thankful if someone knows if it's possible or if there is another way of doing it:

Code:
<script language="JavaScript" type="text/JavaScript">

</script>
 
PHP executes on the server only. To get the results you want you will have to output JavaScript code with php.

Here's the code that will make your test program work.

Code:
<script language="JavaScript" type="text/JavaScript">

</script>
 
Back
Top