Using current WAMP.
If I create an array with 700 keys, each only holding a 6 digit code, and pass it to another page I see all 700 codes. (Array[1]…array[700])
But, If I make two array’s, each with 700 keys, once they are passed I only see 500 of each. The sizeof(array) shows only 500 even though I filled 700. If I remove either array from being passed I will see all 700.
I can not figure this out. It always only sends 500 if I send more than 1 array with more than 500 keys.
My largest post memory is 16mb so I am not running out of memory. I am really stumped.
How are the arrays being passed?
Hello,
I am POSTING the arrays.
Again, getting the post and displaying the array on the next page will show all 700 items in the array until I post with another array that has more than 500 items, then only the FIRST 500 items in each array are posted.
I checked the sizeof(array) and it shows the size of both arrays to be 500 when both are posted. If only ONE array (that has more than 500 items -keys-) is posted then the sizeof(array) will show 700.
I am wondering if there is some sort of ini setting that is causing this.
Below is a basic example
[php]//form page
<?php start_session(); code that gets data from mysql ; while ($prowid = mysql_fetch_array($restultid, MYSQL_ASSOC)) { // 700 keys - rows - items - whatever you want to call it $tempid = $prowid['proid']; ; Blah; Blah Blah; Blah halB; ; ; //#2 } ; ; ?> // end form page// start update posted page
<?php start_session(); $rblah = $_POST['rblah']; $rproid = $_POST['proid']; //#2 foreach ($blah as $key=>$value) { $blah = $rblah[$key]; $proid = $rproid[$key]; echo "you selected $blah - id $proid"; } ?> // end update posted page[/php]I found the problem.
My versionof PHP in my WAMP server limits max_input_vars to 1000. This is a default and was not listed in the php.ini. Once I added max_input_vars = 2000, restart the server, it worked.
you didn’t have to do it that way, you could’ve used ini_set() to change it on the fly.