Friday, January 1, 2010

PHP: convert php array to javascript array

sometimes need convert php array to javascript array. If your hosting service meet these requirements (PHP 5 >= 5.2.0, PECL json >= 1.2.0). You can do this with json_encode function



If you don't have json_encode function, you can use this function.

No comments:

Post a Comment

 
Software