I want to pass a 2D array from javascript to PHP. but the result I get only part of the array.
I use arr.length to check the size is 75.
and I use firefox developer tool to check the data posted is normal.
but I use sizeof($arr) in PHP to check the size of 43.
I use apache as the server. the content of array is string but not more than 10 character.
the following is the code I used.
javascript:
myCol= 0 + $('#tabResult th').length; //75
myRow= 0 + $('#tabResult tr').length; //62
var data = new Array(myRow);
for(i = 0; i < myRow; i++){
data[i] = new Array(75);
}
$.post('getReport1/getReport1ExportXls',{
table: $('#getReport1List').html(),
data: data,
myCol: myCol,
myRow: myRow
},function(o){
openXls();
});
`
PHP:
$data=$_POST['data'];
Update 1:
In fact, the final array size(row x column) is closely to 1000. I already try to change php.ini max_input_vars = 30000
and run httpd -k restart
but no effect.