I have a two dimensional javascript array that I want to assign to a php array.
I tried the following but it did not work:
var js_array= [[]];
js_array = <?php echo $result;?>;
I have basically created a two dimensional php array and assigned to a two dimensional javascript array.
I don't seem to see any logical issue in this code. Can someone please point out as to why this approach might not work?
Thanks.
$result? If it itself is the array, the code will bejs_array = Array;; if it's a string, how did you build it?