- var_dump: documentation ( source)
- next: documentation ( source)
<?php
$a = array(1, 2, 3);
$b = array(
'lol' => 'whut',
'ohgod' => 'why',
'please' => 'stop',
);
next($b);
foreach ($a as $v) {
var_dump($v);
if ($v == 2) {
// this array is lame, let's bail
$a = $b;
}
}