/home/techb158/workloadmatch.com/workloadmatch.com/BackUp/Teacher/Inc
NameSizeModeActions
AddClient.php41710644editdlrm
AddCoursePreference.php189950644editdlrm
updateclient.php27280644editdlrm
UpdateClient1.php27260644editdlrm
Update_Course_Preference.php114680644editdlrm
Update_Course_Preference_Secretarial.php41290644editdlrm
Update_Profile.php45140644editdlrm
Update_Reference.php91310644editdlrm
Update_Reference_Follow_Up.php74350644editdlrm
Edit: /home/techb158/workloadmatch.com/workloadmatch.com/BackUp/Teacher/Inc/Update_Profile.php (4514B)
The email address you entered is not valid

'; } //$error_msg .= $FUserNames .' '. $Admin_ID .' '. $LUserNames; // $error_msg .= $FUserNames .' '. $random_salt .' '. $LUserNames .' '. $Address .' '. $Phones .' '. $CompanyNames .' '. $Admin_ID .' '. $email .' '. $password ; $user_n=$_SESSION['user_id']; $stmt = $mysqli->prepare('SELECT * FROM teacher_profile WHERE Teacher_ID = ?'); $stmt->bind_param('s', $user_n); $stmt->execute(); $result = $stmt->get_result(); //$row = $result->fetch_assoc(); $count =$result->num_rows; if($count > 0) { if (empty($error_msg)) { if (!$mysqli->query("UPDATE teacher_profile SET First_Name='$FUserNames', Last_name='$LUserNames', Email='$email', Phone ='$Phones', Time_Slot='$time_slot_combined', prof_lang='$prof_lang', Note='$Note', SMS_Carrier='$Access_Carrier' WHERE User_Name ='$Admin_ID' AND Teacher_ID ='$user_n'")) { header('Location: profile.php?error='.$mysqli->error); // header('Location: profile.php?error=Client failure to update!'); exit(); }else{ header('Location: profile.php?error=User is Updated successfully. Thanks!'); exit(); } } } }else { header('Location: profile.php?error=all information are required!'); exit(); } }else if(isset($_POST["submits"]) && $_POST["submits"]!="") { if (isset ($_POST['p'])) { $password = filter_input(INPUT_POST, 'p', FILTER_SANITIZE_STRING); if (strlen($password) != 128) { // The hashed pwd should be 128 characters long. // If it's not, something really odd has happened $error_msg .= '

Invalid password configuration.

'; } $random_salt = hash('sha512', uniqid(openssl_random_pseudo_bytes(16), TRUE)); // Create salted password $password = hash('sha512', $password . $random_salt); //$error_msg .= $FUserNames .' '. $Admin_ID .' '. $LUserNames; // $error_msg .= $FUserNames .' '. $random_salt .' '. $LUserNames .' '. $Address .' '. $Phones .' '. $CompanyNames .' '. $Admin_ID .' '. $email .' '. $password ; $user_n=$_SESSION['user_id']; $stmt = $mysqli->prepare('SELECT * FROM teacher_profile WHERE Teacher_ID = ?'); $stmt->bind_param('s', $user_n); $stmt->execute(); $result = $stmt->get_result(); $row = $result->fetch_assoc(); $count =$result->num_rows; if($count > 0) { if (empty($error_msg)) { if (!$mysqli->query("UPDATE teacher_profile SET Password ='$password', salt='$random_salt' WHERE User_Name ='".$row['User_Name']."' AND Teacher_ID ='".$user_n."'")) { // header('Location: profile.php?error='.$mysqli->error); header('Location: profile.php?error=Client password failure to update!'); exit(); } } header('Location: profile.php?error=User password is updated successfully. Thanks!'); exit(); } }else { header('Location: profile.php?error=all information are required!'); exit(); } }