$value) { if (empty($value) && in_array($key, $required_fields) === true) { $errors[] = 'You need to fill in all fields.'; break 1; } } if (empty($errors) === true) { if (filter_var($_POST['new_email'], FILTER_VALIDATE_EMAIL) === false) { $errors[] = 'A valid email address is required.'; } else if (user_email_exist($_POST['new_email']) === true && $user_data['email'] !== $_POST['new_email']) { $errors[] = 'That email address is already in use.'; } } } } ?>
$randomString
"; $body .= "Thank you for stay safe and enjoy at".$config['mailserver']['fromName']."
"; $body .= "I am an automatic no-reply e-mail. Any emails sent back to me will be ignored.
"; $mailer->sendMail($user_data['email'], $title, $body, $user_data['name']); } echo "Your new recovery key is: ".$randomString;
if($config['recovery_key']['send_to_mail'])
echo '
Duplicate has been send to your e-mail address: '.$user_data['email'];
echo '