faqts : Computers : Programming : Languages : PHP : Common Problems : Variables

+ Search
Add Entry AlertManage Folder Edit Entry Add page to http://del.icio.us/
Did You Find This Entry Useful?

31 of 70 people (44%) answered Yes
Recently 7 of 10 people (70%) answered Yes

Entry

How can I pass a Javascript variable to a PHP variable?

Feb 28th, 2005 06:27
Philip Olson, Alex Rao, Kate Killick, Valandis Prowler,


The PHP manual has a solution in its FAQ here:
  How can I pass a variable from Javascript to PHP?
  http://php.net/manual/en/faq.html.php#faq.html.javascript-variable
Basically it involves passing variables to GET, and having PHP access
the GET variables. The same can be done through POST or COOKIE.