for each multiple php 1

for each multiple php

foreach($_POST['an_array'] as $key => $an_array) {
	$another_array = $_POST['another_array'][$key];
  		//do whatevercrap you wanna do
}

Here is what the above code is Doing:
1. We’re looping through the first array, $_POST[‘an_array’].
2. We’re getting the value of the second array, $_POST[‘another_array’], at the same index as the first array.
3. We’re doing whatever we want with the values.

Similar Posts