RE: how i assign a js variable to a php variable

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 




> basicly is use hidden inputs as a container for php variables, and transform
> through js.

really? I though the other way round was extremely simple:

echo '<script type="text/javascript">var myPHPvar=eval("('.addslashes(json_encode($myPHPvar)).')");</script>';

why would you use hidden input, plus DOM to get data, etc, etc?

_________________________________________________________________
Show them the way! Add maps and directions to your party invites. 
http://www.microsoft.com/windows/windowslive/products/events.aspx

[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux