mail() function and QK SMTP Server problem

 
Post new topic   Reply to topic    Aprelium Forum Index -> PHP
View previous topic :: View next topic  
Author Message
zzairiez
-


Joined: 13 Feb 2007
Posts: 5

PostPosted: Tue Feb 13, 2007 3:52 am    Post subject: mail() function and QK SMTP Server problem Reply with quote

hello,

Can anybody help me regarding to the problem in sending email using mail() function and QK SMTP Server?

I'm using mail() function and run in the localhost. The script look like this:

<?php


function sendMail()
{
$to = "zzairiez@yahoo.com";
$subject = "testing sending email";
$msg = "I completely understand SMTP servers!";
$headers = "From: zairi@genaxis.com.my";

mail("$to", "$subject", "$msg", "$headers");
echo "message sent!";
}

?>
<html>
<body>
<form name="" method="post" action="md5.php">
<input name="send" type="submit" value="Send">
</form>

<?
if($_POST['send'] == "Send")
{
sendMail();
}
?>

</body>
</html>


I already tried to send email to gmail account and it is successful. However when I'm tried to send to the yahoo account the message from QK SMTP Server tell that "sending email failed".

So, what is the solution regarding to this problem?
It is require setting to the QK SMTP Server to allow me to send email to yahoo account?
Back to top View user's profile Send private message Send e-mail
jlp09550
-


Joined: 05 Jun 2005
Posts: 123
Location: Louisiana, USA

PostPosted: Tue Feb 13, 2007 4:29 am    Post subject: Reply with quote

Have you tried other accounts rather than GMail and Yahoo? If they work, it may be due to Yahoo having a blacklist report on your IP or mail server. -_-;

Are you using a relay?
_________________
Hosted Abyss Sites-
http://jared.chibipaws.com/ - My Stuffs
http://jaredblog.chibipaws.com/ - My Blog
Back to top View user's profile Send private message Send e-mail Visit poster's website AIM Address Yahoo Messenger MSN Messenger
zzairiez
-


Joined: 13 Feb 2007
Posts: 5

PostPosted: Tue Feb 13, 2007 4:45 am    Post subject: Reply with quote

[mail function]
; For Win32 only.
SMTP = localhost

; For Win32 only.
sendmail_from = postmaster@localhost

Above is the setting in my php.ini

Can you tell me more about use a relay?
Is it a kind of setting?
Back to top View user's profile Send private message Send e-mail
jlp09550
-


Joined: 05 Jun 2005
Posts: 123
Location: Louisiana, USA

PostPosted: Tue Feb 13, 2007 4:48 am    Post subject: Reply with quote

Hmm.. try changing that "sendmail_from" to your email address and try again.

If it does not work, then try sending to other email accounts you have. If they all work and the Yahoo one doesn't, then Yahoo has the server IP blacklisted and you cannot send email to them.
_________________
Hosted Abyss Sites-
http://jared.chibipaws.com/ - My Stuffs
http://jaredblog.chibipaws.com/ - My Blog
Back to top View user's profile Send private message Send e-mail Visit poster's website AIM Address Yahoo Messenger MSN Messenger
zzairiez
-


Joined: 13 Feb 2007
Posts: 5

PostPosted: Tue Feb 13, 2007 4:57 am    Post subject: Reply with quote

can we send email from localhost server? or should we install apache on a real server first?
Back to top View user's profile Send private message Send e-mail
jlp09550
-


Joined: 05 Jun 2005
Posts: 123
Location: Louisiana, USA

PostPosted: Tue Feb 13, 2007 5:33 am    Post subject: Reply with quote

zzairiez wrote:
can we send email from localhost server? or should we install apache on a real server first?


Localhost is fine. The problem I am detecting here is the fact Yahoo! Mail Servers are not accepting the emails your server send. What's your mail server's IP address? [hint; use http://ipchicken.com/ to find the IP]
_________________
Hosted Abyss Sites-
http://jared.chibipaws.com/ - My Stuffs
http://jaredblog.chibipaws.com/ - My Blog
Back to top View user's profile Send private message Send e-mail Visit poster's website AIM Address Yahoo Messenger MSN Messenger
zzairiez
-


Joined: 13 Feb 2007
Posts: 5

PostPosted: Tue Feb 13, 2007 6:23 am    Post subject: Reply with quote

[mail function]
; For Win32 only.
SMTP = smtp.genaxis.com.my

The problem has been solved by changing the SMTP = smtp.genaxis.com.my which is my company smtp.

Thank you for give me a view to solved this problem.
Back to top View user's profile Send private message Send e-mail
pkSML
-


Joined: 29 May 2006
Posts: 952
Location: Michigan, USA

PostPosted: Tue Feb 13, 2007 11:10 pm    Post subject: Reply with quote

I can't send email from my local IP address either. I have a mail server, but many domains block it.

I don't send spam and the relay is closed. But my IP is on a list of dynamic IP addresses, and thus earthlink, yahoo, and aol block my email. Gmail gets through, though.

Try your IP at http://www.au.sorbs.net/lookup.shtml
_________________
Stephen
Need a LitlURL?


http://CodeBin.yi.org
Back to top View user's profile Send private message Visit poster's website
Display posts from previous:   
Post new topic   Reply to topic    Aprelium Forum Index -> PHP All times are GMT + 1 Hour
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB phpBB Group