Web hosting account - 841Chapter 44User Authentication$result = mysql_query($query); if (!$result ||
841Chapter 44User Authentication$result = mysql_query($query); if (!$result || mysql_affected_rows() < 1) { $feedback = ERROR--Problem updating password ; return $feedback; } else { return 1; } } } else { $feedback = ERROR--Please enter old password ; return $feedback; } } else { $feedback .= ERROR--New password not long enough ; return false; } } else { $feedback = ERROR--Your passwords do not match ; return $feedback; } } function user_change_email () { global $supersecret_hash_padding; if (validate_email($_POST[ new_email ])) { $hash = md5($_POST[ new_email ].$supersecret_hash_padding); // Send out a new confirm email with a new hash$user_name = strtolower($_COOKIE[ user_name ]); $password1 = strtolower($_POST[ password1 ]); $crypt_pass = md5($password1); $query = UPDATE userSET confirm_hash = $hash , is_confirmed = 0WHERE user_name = $user_name AND password = $crypt_pass ; $result = mysql_query($query); if (!$result || mysql_affected_rows() < 1) { $feedback = ERROR--Wrong password ; return $feedback; } else { // Send the confirmation email$encoded_email = urlencode($_POST[ new_email ]); $mail_body = <<< EOMAILBODYThank you for registering at Example.com. Click this link to confirm your registration: http://localhost/confirm.php?hash=$hash&email=$encoded_emailOnce you see a confirmation message, you will be logged Continued50
If you are looking for cheap and quality webhost to host and run your website check Jboss Web Hosting services.