The "From:" address may have to be the same as your email address on the SMTP host, otherwise it might reject it as a spam relay attempt. If that's the case, you can set a separate "Reply-To:" header (with the AddReplyTo() method) so that replies will go there.
I have thought of that and I tried changing the From address to be the same as my email address on the SMTP host, but it still returned the same error..
Is it possible to solve this problem by changing my SMTP server ? Maybe to gmail or yahoo?
You're not using the authentication, so add
PHP Code:
$mailer->SMTPAuth = true;
$mailer->Username = 'yourISPusername';
$mailer->Password = 'yourpassword';
Hopefully now it'll all work and you don't get an error going on about a language file, which actually has nothing to do with a language file.
<?php
$mailer->SMTPAuth = true;
$mailer->Username = 'myispusername';
$mailer->Password = 'password';
mail("xxxx@hotmail.com","Hello","Testing");
?>
I added the authentication above into the script, however it still returned the same error.
Warning: mail() [function.mail]: SMTP server response: 530 Authentication required in C:\wamp\www\firstmail.php on line 6