0) { /* this specific string can never be at the position 0 in a html-file, as a quote or double quote must precede. If pos=0, the needle is not found. */ $candpage=substr($ndx_array[$i], $pos, strpos($ndx_array[$i], "\"", $pos) - $pos); if (strpos($candpage, 'page='.$page) > 0) {$nextexit++;} /* this specific string can never be at the position 0 in a html-file, as pages.phtml? must precede. If strpos=0, the needle is not found. */ else { if ($nextexit == 0) {$prevpage = $candpage;} else {$nextpage = $candpage; $nextexit++;}; }; } elseif ($nextexit == 1) {$nextexit++; } elseif ($prevpage != '') {$prevpage = ''; } $i++; } while (($i