3v4l.org

run code in 300+ PHP versions simultaneously
<?php function printtaktyka ($fighter_session, $fighter_name) { global $lg_submitVT, $lg_taktykaT; $query = "SELECT abyss_tryb from XF_abyss WHERE fighter_name = '$fighter_name' "; $result = mysql_query ($query); $row = mysql_fetch_array ($result); $abyss_tryb = $row ["abyss_tryb"]; $tryby[1]="EKSPLORACJA"; $tryby[2]="POLOWANIE"; $tryby[3]="WIEDZA"; $napisy[1]="$lg_taktykaT[1]";//Eksploracja $napisy[2]="$lg_taktykaT[2]";//Polowanie $napisy[3]="$lg_taktykaT[3]";// Wiedza for ($j=1; $j<4 ; $j++) { if ($tryby[$j] == $abyss_tryb) {$obecna=$napisy[$j];} } echo ('<form name="formularz2" method="post" action="taktyka.php"><div align="left"> '); //print ("<BR><input type=\"hidden\" name=\"path\" value=\"$fchar_way_val\" >"); print(" $obecna $lg_taktykaT[0] <BR> "); for ($i=1; $i<4 ; $i++) { $data1 = $abyss_tryb; $data2 = $tryby[$i]; $data3 = $napisy[$i]; if ($data2 == $data1) { print ("<br><input type=\"radio\" form =\"formularz2\" name=\"ab\" value=\"$data2\" checked > $data3 "); } else { print ("<br><input type=\"radio\" form =\"formularz2\" name=\"ab\" value=\"$data2\" > $data3 "); } } echo "<br><input type=\"submit\" name=\"submit\" value=\"$lg_submitVT[0]\">"; echo ('</form></div> '); } ?>
Output for 4.3.0 - 4.3.11, 4.4.0 - 4.4.9, 5.0.0 - 5.0.5, 5.1.0 - 5.1.6, 5.2.0 - 5.2.17, 5.3.0 - 5.3.29, 5.4.0 - 5.4.45, 5.5.0 - 5.5.35, 5.6.0 - 5.6.28, 7.0.0 - 7.0.20, 7.1.0 - 7.1.33, 7.2.0 - 7.2.33, 7.3.0 - 7.3.33, 7.4.0 - 7.4.33, 8.0.0 - 8.0.30, 8.1.0 - 8.1.28, 8.2.0 - 8.2.18, 8.3.0 - 8.3.6

preferences:
225.66 ms | 406 KiB | 374 Q