- Joined
- Apr 13, 2009
- Messages
- 247
- Reaction score
- 95
Hey guys,
Ive basically set up a password reset script..
Because the script relies on sending the users emails, i would like to check if the mail server is turned on and working properly before letting people access the password reset page. Is there anyway to do this?
Thanks!
EDIT:
Ive come up with this so far, however i dont know if its the best way to do things and probs isnt resource efficent:
Please comment on whats the best thing to do...
Ive basically set up a password reset script..
Because the script relies on sending the users emails, i would like to check if the mail server is turned on and working properly before letting people access the password reset page. Is there anyway to do this?
Thanks!
EDIT:
Ive come up with this so far, however i dont know if its the best way to do things and probs isnt resource efficent:
PHP:
if(!@mail("admin@localhost","","","From:")) {
echo'<div class="error">Password resetting is currently disabled. Sorry for any inconvenience.</div>';
} else {
// Allow access
} else {
Please comment on whats the best thing to do...
Last edited:

