for numbers:
jsarray= new Array(<?=  implode(',',$phparray) ?>);

for strings:
jsarray= new Array("<?=  implode('","',$phparray) ?>");

Christian Ista wrote:


Could you tell me how to transform a PHP query result to a javascript array ?

Same question, if you want to store several field from the query to the javascript.


PHP General Mailing List (
To unsubscribe, visit:

Reply via email to