Hello I\'m trying to pass several arrays from php to javascript. For some of them it works, for others not. I get an array of filenames and an array which contains the content o
Some general advice:
php.log
, error.log
, or httpd.log
or ask your server admin(s).Try using print_r() on your arrays to see if there's any difference in how they're structured. For example, just after setting the arrays in PHP:
print_r($fileArray);
print_r($listTextArray);
print_r($falseArray);
Rather than constructing the JS arrays via loops, try using the built-in json_encode() function instead. This both simplifies your PHP code and may cause more useful error messages when there are problems:
var filesArray=;
var falseArray=;
var textListArray=;