Regex Iteration: Every first, second, third of set in array?
Posted: Wed May 07, 2008 5:01 pm
Here is post data with blank values...
So how can I create foreach loop that uses a regex that matches each key which ends with '3'. So the output of the above would end up being...
This code generates the above quote....ce00=
ce01=
ce02=
ce03=
ce10=
ce11=
ce12=
ce13=
ce20=
ce21=
ce22=
ce23=
Code: Select all
foreach($_POST as $key => $value)
echo $key."=".$value.'<br />';ce03=
ce13=
ce23=