Re: [PHP] Mail Function In PHP
Having worked at a decent sized, respectable ISP with 100,000+ customers sending email via Iron Ports (email scanners), even they would get put on a blacklist on a monthly basis. Hell it wouldn't surprise me if Gmail's SMTP servers got put on a black list at some point. There's seemingly hundreds of blacklists and whilst some play nice, others are very paranoid. Usually the good email servers will detect your on a blacklist then rate limit the number of emails it'll accept from you. If you keep pissing it off, by sending emails to non-existant addresses (something they REALLY hate), sending emails that are too big, or simply sending too many emails or emails with too many recipients, then it'll tighten the restrictions. Over time if your good then those restrictions will be released and eventually you'll be able to send at normal rates. -- Michael Kubler I believe in a better world. I support the Zeitgeist Movement -- www.zeitgeistaustralia.org Teus Benschop wrote: Once a domain or ip address was black listed, it was quite a process to get it unlisted again, and even then as soon as mail came from that domain, it got blacklisted again. Supposedly there is some certification process that official smtp relays need to go through so as to prove or certify that they won't allow spam to be sent through them, and take steps to remove offenders from using their relay. However, this is all guessing, and in the end we just gave up and used our ISP's official relay. Teus. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Mail Function In PHP
On 7 March 2010 04:54, Kannan kanna...@gmail.com wrote: Hello I am creating a application for our college using the php.In that i want to send mail to all who are all the list. For that i am just simply use the mail function in php without configuring any mail system in the system.But the mail didn't send. For sending the mails wat are requirements and if u have any tutorials send it to me? Thanks.. -- With regards, Kannan. R. P, Blog @: http://kannan4k.wordpress.com/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php Contrary to popular belief, to send an email you do not need to have your own SMTP server. All you need to know is the SMTP server responsible for your recipients email. This information is held as part of the domain registration details and is known as the MX records (as I understand it). PHP has a function called getmxrr() [1]. This allows you to supply a domain name and get back the list of MX records suitable for handling the SMTP mail. This function wasn't available on Windows until recently, and I created a userland version utilising Windows nslookup.exe program [2]. So, once you've got the list of SMTP servers for the domain you are sending email to, you can use the ini_set('SMTP', 'xx'); function to set the server to handle the mail() call you are about to make. Upside : No local SMTP server - you are not responsible for maintaining/administering/etc. any aspect of the SMTP process. Upside : If the mail() call fails, you can try the other MX records (I tend to sort the results based upon weight and try them in sequence). If it fails all of them, you know straight away and can deal with it. Upside : No relaying. No permission issues to worry about. You are simply talking to the public SMTP servers just like any other SMTP server or sender. Downside : No queuing. Without a _LOCAL_ SMTP server, you can only deal with sending email in real time. Downside : One domain at a time. You cannot send email to a...@domain1.com, b...@domain2.com _AND_ c...@domain3.com in the 1 email. None of these steps affect the use of mail() or a mail sending class (phpmailer, RMail, html_mime_mail5, etc.). Regards, Richard. [1] http://docs.php.net/getmxrr [2] http://docs.php.net/getmxrr#53182 Richard. -- - Richard Quadling Standing on the shoulders of some very clever giants! EE : http://www.experts-exchange.com/M_248814.html EE4Free : http://www.experts-exchange.com/becomeAnExpert.jsp Zend Certified Engineer : http://zend.com/zce.php?c=ZEND002498r=213474731 ZOPA : http://uk.zopa.com/member/RQuadling -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Mail Function In PHP
On Mon, 2010-03-08 at 10:21 +, Richard Quadling wrote: Contrary to popular belief, to send an email you do not need to have your own SMTP server. All you need to know is the SMTP server responsible for your recipients email. [...] While the above is true, there is also another thing that comes into play. We used to send email directly to the receiver the way described above. But at times it happens that the receiving smtp server refuses to accept mail from the sender since the sender is not known to be a good smtp server, and at times it could get blacklisted. Rules like this get tightened up because of the desire to curb spam at the source. Teus. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Mail Function In PHP
On 8 March 2010 13:06, Teus Benschop teusjanne...@gmail.com wrote: On Mon, 2010-03-08 at 10:21 +, Richard Quadling wrote: Contrary to popular belief, to send an email you do not need to have your own SMTP server. All you need to know is the SMTP server responsible for your recipients email. [...] While the above is true, there is also another thing that comes into play. We used to send email directly to the receiver the way described above. But at times it happens that the receiving smtp server refuses to accept mail from the sender since the sender is not known to be a good smtp server, and at times it could get blacklisted. Rules like this get tightened up because of the desire to curb spam at the source. Teus. Black listing can happen even for valid domains. -- - Richard Quadling Standing on the shoulders of some very clever giants! EE : http://www.experts-exchange.com/M_248814.html EE4Free : http://www.experts-exchange.com/becomeAnExpert.jsp Zend Certified Engineer : http://zend.com/zce.php?c=ZEND002498r=213474731 ZOPA : http://uk.zopa.com/member/RQuadling -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Mail Function In PHP
On 8 March 2010 13:06, Teus Benschop teusjanne...@gmail.com wrote: On Mon, 2010-03-08 at 10:21 +, Richard Quadling wrote: Contrary to popular belief, to send an email you do not need to have your own SMTP server. All you need to know is the SMTP server responsible for your recipients email. [...] While the above is true, there is also another thing that comes into play. We used to send email directly to the receiver the way described above. But at times it happens that the receiving smtp server refuses to accept mail from the sender since the sender is not known to be a good smtp server, and at times it could get blacklisted. Rules like this get tightened up because of the desire to curb spam at the source. Teus. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php So, say I did go and setup a local SMTP relay, how would I make it known that it was a real smtp server and not just some script pushing spam? -- - Richard Quadling Standing on the shoulders of some very clever giants! EE : http://www.experts-exchange.com/M_248814.html EE4Free : http://www.experts-exchange.com/becomeAnExpert.jsp Zend Certified Engineer : http://zend.com/zce.php?c=ZEND002498r=213474731 ZOPA : http://uk.zopa.com/member/RQuadling -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Mail Function In PHP
On Mon, 2010-03-08 at 17:18 +, Richard Quadling wrote: On 8 March 2010 13:06, Teus Benschop teusjanne...@gmail.com wrote: On Mon, 2010-03-08 at 10:21 +, Richard Quadling wrote: Contrary to popular belief, to send an email you do not need to have your own SMTP server. All you need to know is the SMTP server responsible for your recipients email. [...] While the above is true, there is also another thing that comes into play. We used to send email directly to the receiver the way described above. But at times it happens that the receiving smtp server refuses to accept mail from the sender since the sender is not known to be a good smtp server, and at times it could get blacklisted. Rules like this get tightened up because of the desire to curb spam at the source. Teus. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php So, say I did go and setup a local SMTP relay, how would I make it known that it was a real smtp server and not just some script pushing spam? -- - Richard Quadling Standing on the shoulders of some very clever giants! EE : http://www.experts-exchange.com/M_248814.html EE4Free : http://www.experts-exchange.com/becomeAnExpert.jsp Zend Certified Engineer : http://zend.com/zce.php?c=ZEND002498r=213474731 ZOPA : http://uk.zopa.com/member/RQuadling By having your local relay talk seductively to the remote server? More sensibly though, I would assume that you could use some sort of certificate for this, although I don't know much about mail servers. Thanks, Ash http://www.ashleysheridan.co.uk
Re: [PHP] Mail Function In PHP
If you control your DNS server setup and such, DKIM and authentication technologies alikes (http://en.wikipedia.org/wiki/DomainKeys) are the way to go. Also, make sure the reverse DNS lookup is pointing to the right place, i.e. that the SMTP server domain name translates to an IP that translates back to the same domain name when you do a reverse lookup. Since this is really something more of a network arch. setup, you probably will find more answers for that on ServerFault or the likes. MT On Tue, Mar 9, 2010 at 2:18 AM, Ashley Sheridan a...@ashleysheridan.co.ukwrote: On Mon, 2010-03-08 at 17:18 +, Richard Quadling wrote: On 8 March 2010 13:06, Teus Benschop teusjanne...@gmail.com wrote: On Mon, 2010-03-08 at 10:21 +, Richard Quadling wrote: Contrary to popular belief, to send an email you do not need to have your own SMTP server. All you need to know is the SMTP server responsible for your recipients email. [...] While the above is true, there is also another thing that comes into play. We used to send email directly to the receiver the way described above. But at times it happens that the receiving smtp server refuses to accept mail from the sender since the sender is not known to be a good smtp server, and at times it could get blacklisted. Rules like this get tightened up because of the desire to curb spam at the source. Teus. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php So, say I did go and setup a local SMTP relay, how would I make it known that it was a real smtp server and not just some script pushing spam? -- - Richard Quadling Standing on the shoulders of some very clever giants! EE : http://www.experts-exchange.com/M_248814.html EE4Free : http://www.experts-exchange.com/becomeAnExpert.jsp Zend Certified Engineer : http://zend.com/zce.php?c=ZEND002498r=213474731 ZOPA : http://uk.zopa.com/member/RQuadling By having your local relay talk seductively to the remote server? More sensibly though, I would assume that you could use some sort of certificate for this, although I don't know much about mail servers. Thanks, Ash http://www.ashleysheridan.co.uk -- Marc Trudel-Bélisle www.wizcorp.jp
Re: [PHP] Mail Function In PHP
On Mon, 2010-03-08 at 17:18 +, Richard Quadling wrote: So, say I did go and setup a local SMTP relay, how would I make it known that it was a real smtp server and not just some script pushing spam? Once a domain or ip address was black listed, it was quite a process to get it unlisted again, and even then as soon as mail came from that domain, it got blacklisted again. Supposedly there is some certification process that official smtp relays need to go through so as to prove or certify that they won't allow spam to be sent through them, and take steps to remove offenders from using their relay. However, this is all guessing, and in the end we just gave up and used our ISP's official relay. Teus. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Mail Function In PHP
On 03/08/2010 06:18 PM, Richard Quadling wrote: On 8 March 2010 13:06, Teus Benschopteusjanne...@gmail.com wrote: On Mon, 2010-03-08 at 10:21 +, Richard Quadling wrote: Contrary to popular belief, to send an email you do not need to have your own SMTP server. All you need to know is the SMTP server responsible for your recipients email. [...] above. But at times it happens that the receiving smtp server refuses to accept mail from the sender since the sender is not known to be a good smtp server, and at times it could get blacklisted. Rules like this get tightened up because of the desire to curb spam at the source. Teus. So, say I did go and setup a local SMTP relay, how would I make it known that it was a real smtp server and not just some script pushing spam? You can use SPF, DomainKeys plus valid DNS information. I have setup SPF records for my domains. If you attempt to send E-Mail as if it was sent from my server then any server doing SPF record checking will not accept or simply drop your message. I have not setup DomainKeys since SPF has served me well but I will configure it soon. -- John Insanity in individuals is something rare - but in groups, parties, nations and epochs, it is the rule. [Friedrich Nietzsche] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Mail Function In PHP
On 03/08/2010 10:45 PM, John Black wrote: You can use SPF, DomainKeys plus valid DNS information. I have setup SPF records for my domains. If you attempt to send E-Mail as if it was sent from my server then any server doing SPF record checking will not accept or simply drop your message. I have not setup DomainKeys since SPF has served me well but I will configure it soon. woops, forgot to add that I doubt that you'll be able to get a pure webserver to do this for you, reliably, since some smtp servers will call your server back and check if the e-mail account exists. I'd assume that the server will drop the mail if your script sending server is not even running smtp on port 25. -- John Niemand ist frei, der über sich selbst nicht Herr ist. [Matthias Claudius] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Mail Function In PHP
Any volume of mail sent direct to mx records is a red flag for anti spammers and without an smtp spf dkim and rdns you are wasting your time. The logic is that only people sending spam would be sending direct to mx like that. Fair or not that is just how life works. Oh and most mail servers do check rdns spf etc. It is kind of pointless to send emails if they end up in the spam folder or worse don't get delivered at all. Do it right the first time use an smtp rdns and spf at the very least. Sent via BlackBerry from T-Mobile -Original Message- From: Richard Quadling rquadl...@googlemail.com Date: Mon, 8 Mar 2010 10:21:53 To: Kannankanna...@gmail.com Cc: php-general@lists.php.net Subject: Re: [PHP] Mail Function In PHP On 7 March 2010 04:54, Kannan kanna...@gmail.com wrote: Hello I am creating a application for our college using the php.In that i want to send mail to all who are all the list. For that i am just simply use the mail function in php without configuring any mail system in the system.But the mail didn't send. For sending the mails wat are requirements and if u have any tutorials send it to me? Thanks.. -- With regards, Kannan. R. P, Blog @: http://kannan4k.wordpress.com/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php Contrary to popular belief, to send an email you do not need to have your own SMTP server. All you need to know is the SMTP server responsible for your recipients email. This information is held as part of the domain registration details and is known as the MX records (as I understand it). PHP has a function called getmxrr() [1]. This allows you to supply a domain name and get back the list of MX records suitable for handling the SMTP mail. This function wasn't available on Windows until recently, and I created a userland version utilising Windows nslookup.exe program [2]. So, once you've got the list of SMTP servers for the domain you are sending email to, you can use the ini_set('SMTP', 'xx'); function to set the server to handle the mail() call you are about to make. Upside : No local SMTP server - you are not responsible for maintaining/administering/etc. any aspect of the SMTP process. Upside : If the mail() call fails, you can try the other MX records (I tend to sort the results based upon weight and try them in sequence). If it fails all of them, you know straight away and can deal with it. Upside : No relaying. No permission issues to worry about. You are simply talking to the public SMTP servers just like any other SMTP server or sender. Downside : No queuing. Without a_LOCAL_ SMTP server, you can only deal with sending email in real time. Downside : One domain at a time. You cannot send email to a...@domain1.com, b...@domain2.com_and_ c...@domain3.com in the 1 email. None of these steps affect the use of mail() or a mail sending class (phpmailer, RMail, html_mime_mail5, etc.). Regards, Richard. [1] http://docs.php.net/getmxrr [2] http://docs.php.net/getmxrr#53182 Richard. -- - Richard Quadling Standing on the shoulders of some very clever giants! EE : http://www.experts-exchange.com/M_248814.html EE4Free : http://www.experts-exchange.com/becomeAnExpert.jsp Zend Certified Engineer : http://zend.com/zce.php?c=ZEND002498r=213474731 ZOPA : http://uk.zopa.com/member/RQuadling -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Mail Function In PHP
Hello I am creating a application for our college using the php.In that i want to send mail to all who are all the list. For that i am just simply use the mail function in php without configuring any mail system in the system.But the mail didn't send. For sending the mails wat are requirements and if u have any tutorials send it to me? Thanks.. -- With regards, Kannan. R. P, Blog @: http://kannan4k.wordpress.com/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Mail Function In PHP
You need SMTP Server for this.. Read bellow link to know more how to configure SMTP Server in PHP http://email.about.com/od/emailprogrammingtips/qt/Configure_PHP_to_Use_a_Remote_SMTP_Server_for_Sending_Mail.htm http://email.about.com/od/emailprogrammingtips/qt/Configure_PHP_to_Use_a_Remote_SMTP_Server_for_Sending_Mail.htm On Sun, Mar 7, 2010 at 10:24 AM, Kannan kanna...@gmail.com wrote: Hello I am creating a application for our college using the php.In that i want to send mail to all who are all the list. For that i am just simply use the mail function in php without configuring any mail system in the system.But the mail didn't send. For sending the mails wat are requirements and if u have any tutorials send it to me? Thanks.. -- With regards, Kannan. R. P, Blog @: http://kannan4k.wordpress.com/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- Devendra Jadhav देवेंद्र जाधव
Re: [PHP] Mail Function In PHP
Kannan wrote: Hello I am creating a application for our college using the php.In that i want to send mail to all who are all the list. For that i am just simply use the mail function in php without configuring any mail system in the system.But the mail didn't send. For sending the mails wat are requirements and if u have any tutorials send it to me? Thanks.. Hello, Read the manual page for the mail() function ... http://www.php.net/mail Mail() requires an operating SMTP server. This can be set in php.ini, and possibly via the ini_set() function. These might be worth looking into: $config1=ini_set(sendmail_path,/usr/sbin/sendmail -t -i); $config2=ini_set(SMTP,localhost); $config3=ini_set(smtp_port,25); If you absolutely can't run an SMTP server or use a remote server, you'd probably have to hack something together with sockets or streams. My $0.02, Kevin Kinsey -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php