Tak wygląda moje drzewo plików:
index.php
switch($_POST['step']) { case 0; { include_once('step1.php'); break; }
step1.php
include_once('top.php'); <input type="image" src="images/dalej.png" value="next" alt="Submit" align="center">
top.php
for ($i = 0; $i<7; $i++){ if($tab[$i] == $tab[$_POST["step"]]){ } else{ } }
Wyskakują dwa ostrzeżenia:
Undefined index: step in \index.php on line 13 - wskazuje na switcha
Notice: Undefined offset: 6 in \top.php on line 16 - gdzie 16 i 21 to linijka z if i z echo $tab[$i]
Notice: Undefined offset: 6 in \top.php on line 21