$password = $con->real_escape_string($_POST['ca_password']); if ($UserController->create($username, $email, $password)) { echo 'Account Created'; } } if (isset($_POST['submit_settings'])) { $fname = $con->real_escape_string($_POST['fname']); $lname = $con->real_escape_string($_POST['lname']); if ($UserController->edit($fname, $lname, $User['id'])) { header('Location:/settings.php'); } } if (isset($_POST['change_password_submit'])) { if ($_POST['change_password'] == $_POST['con_change_password']) { $edit_password = md5($_POST['change_password']); if ($UserController->editpassword($edit_password, $User['id'])) { header('Location:/settings.php'); } } else { echo 'Passwords do not match'; } } ?> <html> <head> <title>Forum</title> <link rel="stylesheet" href="/public/bootstrap/bootstrap.css" /> <link rel="stylesheet" href="/public/bootstrap/bootstrap-theme.css" /> <link rel="stylesheet" href="/public/css/main.css"/> <script type="text/javascript" src="public/js/jquery-2.1.4.min.js"></script> <script type="text/javascript" src="/public/bootstrap/bootstrap.min.js"></script>