3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php include ('inc/header.php'); $userUsername1 = $_POST['userUsername']; $userChangePassword = md5($_POST['userChangePassword']); $userChangePasswordConfirm = md5($_POST['userChangePasswordConfirm']); $userSecretCode = md5($_POST['userSecretCode']); $sql4 = "SELECT * FROM userinformation WHERE user_username = '" . $userUsername1 . "'"; $data2 = mysql_query($sql4, $cn) or die (mysql_error($cn)); $rowPW = mysql_num_rows($data2); $row1214 = mysql_fetch_assoc($data2); $DBuName = $row1214['user_username']; $DBCode = $row1214['user_code']; if ($userUsername1 == $DBuName){ if ($userSecretCode == $DBCode){ if ($rowPW == 1){ if ($userChangePassword != $userChangePasswordConfirm){?> <div class = "container" id = "bodyContainerVideo"> <div class = "row"> <div class = "col-md-12"> <h1 class = "Main-Title">Your new passwords do not match.</h1> </div> </div> </div> </body> </html><?php } else { $sql5 = "UPDATE userinformation SET user_password = '" . $userChangePassword . "' WHERE user_username = '" . $userUsername1 . "'"; $result5 = mysql_query($sql7, $cn) or die(mysql_error($cn));?> <div class = "container" id = "bodyContainerVideo"> <div class = "row"> <div class = "col-md-12"> <h1 class = "Main-Title">Your password has been sucessfully been changed</h1> </div> </div> </div> </body> </html> <?php } } else {?> <div class = "container" id = "bodyContainerVideo"> <div class = "row"> <div class = "col-md-12"> <h1 class = "Main-Title">The code that you put in is incorrect</h1> </div> </div> </div> </body> </html> <?php } else {?> <div class = "container" id = "bodyContainerVideo"> <div class = "row"> <div class = "col-md-12"> <h1 class = "Main-Title">Username does not exist.</h1> </div> </div> </div> </body> </html> <?php } } include ('inc/footer.php'); ?>
based on L81la
Output for 5.4.0 - 5.4.35
Parse error: syntax error, unexpected 'else' (T_ELSE) in /in/r9lO5 on line 57
Process exited with code 255.
Output for 4.4.2 - 4.4.9, 5.1.0 - 5.3.29
Parse error: syntax error, unexpected T_ELSE in /in/r9lO5 on line 57
Process exited with code 255.
Output for 4.3.0 - 4.3.1, 4.3.5 - 4.4.1, 5.0.0 - 5.0.5
Parse error: parse error, unexpected T_ELSE in /in/r9lO5 on line 57
Process exited with code 255.
Output for 4.3.2 - 4.3.4
Parse error: parse error in /in/r9lO5 on line 57
Process exited with code 255.