不确定代码错误是什么


Unsure of what code Error is

我一直在研究一个代码,使用数据库中的变量(例如他们的密码)来更改数据库中某人的密码(例如,如果他们忘记了代码)。

每当我尝试运行该函数时,我总是收到此错误:解析错误:语法错误,C:''xampp''htdocs''PhysicsProject''resetPasswordConnection.php 第 70 行中的文件意外结束。

以下是导致错误的代码:

   <?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');
?>

有人可以帮我吗?

更改此设置(应为第 58 行):

<?php}

对此(您只需要最少 1 个空格):

<?php  //this also works <?php } but this not <?php}
}