Click to See Complete Forum and Search --> : SMTP SERVER || problems or errors not sure


katten
04-07-2006, 03:46 PM
O well i was making a password recovoery system for my homepage so i installed a smtp server (hmailserver) so that i could use the mail function everything workt but when i tried the script i got this error

Warning: mail() [function.mail]: SMTP server response: 550 Delivery is not allowed to this address. in C:\webserver\www\windsurf\mod\login\login.forgotten.view.php on line 17

My php code anyone got any idea?

<?php
if($HttpData->SendForm == "Submit")
{
$query = $db->select('users', array('user','email'), array('user' => $HttpData->UserName, 'email' => $HttpData->UserEmail), array('id' => 'desc'), '');
$sql = mysql_fetch_assoc($query) or die(mysql_error());
if(mysql_num_rows($query) == 1)
{


$message = "Du har bett om ett nytt lösenord,
Detta e ditt nuvarande lösenord: ".$sql['password']." .
Om du inte bad om att få vet ditt lösenord igen så bör du åt ta tanken att nån försöker hacka dej.

Din Administrator Antoine.
";
$message = str_replace("\n","\n..", $message);
mail($sql['email'], "Password recovery, Windsurf.servehttp.com", $message, "From: DontReply@windsurf.servehttp.com");

return $value = array('message' => 'Ditt nya lösenord har skickat till din email.');
$cookie->WaitTimeRecoveryPassword = time() + 10 * 60;

} else {

$cookie->WaitTimeRecoveryPassword = time() + 10 * 60;
return $value = array('message' => 'Den användar finns inte, eller så stämmer inte E-mail adressen med den användaren.');
}
}
?>


If you find the problem explain it not just give me a answere

Note: This script is written by me and i'm 14 years old.

SpectreReturns
04-07-2006, 03:50 PM
Does your SMTP server currently allow relay? If not, that's your problem.

katten
04-07-2006, 03:57 PM
Could you explain to me what relay is i'm only 14 years old so i got lots of fun stuff to learn..

katten
04-08-2006, 01:09 AM
anyone got a answere ??

SpectreReturns
04-08-2006, 03:32 AM
Relay is the ability for the mail server to send the mail to another mail server. Without relay, it can only send messages to other accounts on the same host.