[PHP] using mail() for multiple email address...
Hello all, I have a strange problem with the mail() function. It may not be php at all. I have multiple email accounts at my website. I just started testing the mail() function to learn how it works. When I send to multiple address' separating them via a comma, all goes well until I send the same email to my main account and another address that in turn redirects it to my main account. For example: if (mail([EMAIL PROTECTED], [EMAIL PROTECTED], test, no body really...)) print(successful); else print(unsuccessful); Normally, the two emails would end up in the same pop account but don't seem to be when I use the above script. If I send to one or the other they receive appropriately, but if I send to both at the same time, I only receive one email, not both. If anyone can help me as to why this is and if there is a remedy, I'd sure like to know about it. Thanks a lot!! -Adam Reiswig -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] using mail() for multiple email address...
Hello all, I have a strange problem with the mail() function. It may not be php at all. I have multiple email accounts at my website. I just started testing the mail() function to learn how it works. When I send to multiple address' separating them via a comma, all goes well until I send the same email to my main account and another address that in turn redirects it to my main account. For example: if (mail([EMAIL PROTECTED], [EMAIL PROTECTED], test, no body really...)) print(successful); else print(unsuccessful); Normally, the two emails would end up in the same pop account but don't seem to be when I use the above script. If I send to one or the other they receive appropriately, but if I send to both at the same time, I only receive one email, not both. If anyone can help me as to why this is and if there is a remedy, I'd sure like to know about it. Thanks a lot!! -Adam Reiswig -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] using mail() for multiple email address...
Hello all, I have a strange problem with the mail() function. It may not be php at all. I have multiple email accounts at my website. I just started testing the mail() function to learn how it works. When I send to multiple address' separating them via a comma, all goes well until I send the same email to my main account and another address that in turn redirects it to my main account. For example: if (mail([EMAIL PROTECTED], [EMAIL PROTECTED], test, no body really...)) print(successful); else print(unsuccessful); Normally, the two emails would end up in the same pop account but don't seem to be when I use the above script. If I send to one or the other they receive appropriately, but if I send to both at the same time, I only receive one email, not both. If anyone can help me as to why this is and if there is a remedy, I'd sure like to know about it. Thanks a lot!! -Adam Reiswig -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP] using mail() - what is max number of email addresses I can specify in To field?
Here's some of my considerations ;) First of all, for the matter of anti-spam, please do not use the to for more people than, well .. Usually just one actually. Rather use the 'Bcc:' line. If there's no personalized information in the email (you might, for example, want to start with Good Afternoon John for a mail to a fella named John), I'd split up the list in chunks of 20 or 50 or smth. Or at least an amount every mailer could handle. Also, you'll probably want to group those chunks by domain. That way your mailersoftware will have to connect to as little different addessas as possible. Just specify your own address as 'To:' of you want to use only BCC. Or even better, specify something like Undisclosed Recepients [EMAIL PROTECTED] so those mails will just vanish out of existence. Or you can, as suggested, make one mail for every recepient. Looks more personal anyways. I'm not sure if it increases the speed here also if you give your messages to mail sorted on domain name but I know it won't hurt ;). Hope I helped a bit, Wouter -Original Message- From: Rolf Brusletto [mailto:[EMAIL PROTECTED] Sent: Thursday 23 October 2003 06:54 To: John Christopher Cc: [EMAIL PROTECTED] Subject: Re: [PHP] using mail() - what is max number of email addresses I can specify in To field? It really depends on the mta you use... if your going to use mail(); the I would put the list of addresses in an array and the do foreach($addressArray as $address) { mail($address,'Here is your subject','Here is your content'); } Rolf Brusletto http://www.phpexamples.net John Christopher wrote: I am writing a script that will query a database table for some statistical information, and then email it (daily, weekly, and monthly) to a list of subscribers. I don't know ahead of time how many persons will be subscribed to receive the info (it could be 20 persons or 2000 or more). Email addresses can be added to or deleted from the subscriber list at any time. If I am not mistaken, MTAs have a limit on how many recipients can be specified on the To: line of an email message. What is the limit, or does it depend on the MTA you're using (sendmail, qmail, etc), or other factors? If there is such a limit, then what is the best way to send the message to each recipient? Thank you. __ Do you Yahoo!? The New Yahoo! Shopping - with improved product search http://shopping.yahoo.com -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] using mail() - what is max number of email addresses I can specify in To field?
I am writing a script that will query a database table for some statistical information, and then email it (daily, weekly, and monthly) to a list of subscribers. I don't know ahead of time how many persons will be subscribed to receive the info (it could be 20 persons or 2000 or more). Email addresses can be added to or deleted from the subscriber list at any time. If I am not mistaken, MTAs have a limit on how many recipients can be specified on the To: line of an email message. What is the limit, or does it depend on the MTA you're using (sendmail, qmail, etc), or other factors? If there is such a limit, then what is the best way to send the message to each recipient? Thank you. __ Do you Yahoo!? The New Yahoo! Shopping - with improved product search http://shopping.yahoo.com -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] using mail() - what is max number of email addresses I can specify in To field?
I'm not sure if you've considered this possibility--but can't you send the messages to one recipient at a time? This way, the problem wouldn't present itself, and the end result would be quite the same (with the added bonus of not having to disclose your entire mailing list to each recipient). To speed things up, you may want to look at the PHPMailer project (http://phpmailer.sourceforge.net/), which provides a class that facilitates sending the same message to multiple recipients, as well as other aspects of e-mailing, like HTML bodies and attachments. Finally--if you're sending lots of e-mail I recommend you monitor your MTA carefully--Sendmail has a habit of choking on large mailings, whereas learner MTAs like Exim or Qmail seem to do better. Cheers, Marco John Christopher wrote: I am writing a script that will query a database table for some statistical information, and then email it (daily, weekly, and monthly) to a list of subscribers. I don't know ahead of time how many persons will be subscribed to receive the info (it could be 20 persons or 2000 or more). Email addresses can be added to or deleted from the subscriber list at any time. If I am not mistaken, MTAs have a limit on how many recipients can be specified on the To: line of an email message. What is the limit, or does it depend on the MTA you're using (sendmail, qmail, etc), or other factors? If there is such a limit, then what is the best way to send the message to each recipient? Thank you. __ Do you Yahoo!? The New Yahoo! Shopping - with improved product search http://shopping.yahoo.com -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] using mail() - what is max number of email addresses I can specify in To field?
It really depends on the mta you use... if your going to use mail(); the I would put the list of addresses in an array and the do foreach($addressArray as $address) { mail($address,'Here is your subject','Here is your content'); } Rolf Brusletto http://www.phpexamples.net John Christopher wrote: I am writing a script that will query a database table for some statistical information, and then email it (daily, weekly, and monthly) to a list of subscribers. I don't know ahead of time how many persons will be subscribed to receive the info (it could be 20 persons or 2000 or more). Email addresses can be added to or deleted from the subscriber list at any time. If I am not mistaken, MTAs have a limit on how many recipients can be specified on the To: line of an email message. What is the limit, or does it depend on the MTA you're using (sendmail, qmail, etc), or other factors? If there is such a limit, then what is the best way to send the message to each recipient? Thank you. __ Do you Yahoo!? The New Yahoo! Shopping - with improved product search http://shopping.yahoo.com -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] using mail()
If I am using this code: mail([EMAIL PROTECTED], test, testbody); and want to add a From: line, how do I do it? Also, is this an excepted way of sending mail from a web page? Thanks, Amanda -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP] using mail()
[snip] If I am using this code: mail([EMAIL PROTECTED], test, testbody); and want to add a From: line, how do I do it? Also, is this an excepted way of sending mail from a web page? [/snip] Read http://us4.php.net/manual/en/function.mail.php Example 2 (How's that Chris?) And yes, it is acceptable. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Using mail() function in php.ini (Unix/Linux)
For those of you who don't know it or are struggling with the problem with the slow sending of hte e-mail behind the firewall. This problem doesn't alway lie with the DNS itself. The workaround to the problem is the hostname resolution or the alias to the hostname. Just open up the /etc/hosts file using either vi or emac and add this ... (Substitute the term in the bracket for something else) --clip-- IP Addresshostnamedomain name --clip-- Do not use the dot between the hostname and the domain name. Just like this as you normally see in most host files Ip Addresshostname 1host nickname or secondary name Enjoy. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Using mail() for mailist list app
At 06:33 PM 1/1/03 -0500, Michael J. Pawlowsky wrote: Personally I simply get the e-mail addresses spit out to me from the database and then I input them into a application made just for bulk mailingt. You can also easily write a quick perl or shell script to send it out from a file of names and this way you can nice the process so as not to bog down the machine. PHP now offers a command line SAPI that lets you write these programs with PHP. Leave the names in the database, and use PHP's mail() to send the messages. It works very well. I've been using PHP at the command line for quite a while now. 4.3.0 is the first version that creates the CLI version of PHP by default. Rick -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Using mail() for mailist list app
Happy New Year everyone! Is the PHP mail() command robust enough to use in a little mailing list app? The app will basically send an HTML or Text e-mail to the member database of about 6,000 people. I'm using RedHat Linux 7.2 with PHP 4.2.2, by the way. I'm concerned I'll bog down my server if I issue the mail() command 6,000 times on our server, but, maybe it won't be a problem? Also, although I'm sending HTML e-mail, I'm not including attachments or inline graphics (only direct hotlinks to graphics on a web server). Will mail() still work okay for this, or do I need to use one of the various PHP e-mail classes available to send HTML e-mail? Any recommendations for online tutorials about building a mailing list manager using PHP would be much appreciated! Thanks! Monty -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Using mail() for mailist list app
Check the archives... mail() tends to break pretty quickly... sometimes on less than 100 personalised emails... The issue ISN'T mail() itself, but things like server timeouts, script timeouts, etc etc. The issue also isn't really HTML mail, but more the fact that each email has to be sent to the mail que, and this is a slow-ish process, so the script timesout. So another option is Bcc'ing the email to everyone in a non-personalised manner... you can squeeze a lot more emails out of mail() before the script times out, but you will run into other issues like: a) Bcc'd mails of more than 100 recipients can't be sent on most shared hosts, because it looks like spam -- check with your ISP b) some mail programs and servers treat mass Bcc emails as spam, I hear At the moment, I've only got mailing lists that deals with 50-300 people, so I'm just Bcc'ing them in batches of 20 people... a trade off between lots of emails to timeout the script, and lots of people in the Bcc list. I think for 6000 though, you will really need to look at a class like Manuel's at PHPclasses.org (I think called mimeMail) which has various work-arounds, none of which I've tried. Cheers, Justin on 02/01/03 9:46 AM, Monty ([EMAIL PROTECTED]) wrote: Happy New Year everyone! Is the PHP mail() command robust enough to use in a little mailing list app? The app will basically send an HTML or Text e-mail to the member database of about 6,000 people. I'm using RedHat Linux 7.2 with PHP 4.2.2, by the way. I'm concerned I'll bog down my server if I issue the mail() command 6,000 times on our server, but, maybe it won't be a problem? Also, although I'm sending HTML e-mail, I'm not including attachments or inline graphics (only direct hotlinks to graphics on a web server). Will mail() still work okay for this, or do I need to use one of the various PHP e-mail classes available to send HTML e-mail? Any recommendations for online tutorials about building a mailing list manager using PHP would be much appreciated! Thanks! Monty -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Using mail() for mailist list app
Personally I simply get the e-mail addresses spit out to me from the database and then I input them into a application made just for bulk mailingt. You can also easily write a quick perl or shell script to send it out from a file of names and this way you can nice the process so as not to bog down the machine. *** REPLY SEPARATOR *** On 02/01/2003 at 9:58 AM Justin French wrote: Check the archives... mail() tends to break pretty quickly... sometimes on less than 100 personalised emails... The issue ISN'T mail() itself, but things like server timeouts, script timeouts, etc etc. The issue also isn't really HTML mail, but more the fact that each email has to be sent to the mail que, and this is a slow-ish process, so the script timesout. So another option is Bcc'ing the email to everyone in a non-personalised manner... you can squeeze a lot more emails out of mail() before the script times out, but you will run into other issues like: a) Bcc'd mails of more than 100 recipients can't be sent on most shared hosts, because it looks like spam -- check with your ISP b) some mail programs and servers treat mass Bcc emails as spam, I hear At the moment, I've only got mailing lists that deals with 50-300 people, so I'm just Bcc'ing them in batches of 20 people... a trade off between lots of emails to timeout the script, and lots of people in the Bcc list. I think for 6000 though, you will really need to look at a class like Manuel's at PHPclasses.org (I think called mimeMail) which has various work-arounds, none of which I've tried. Cheers, Justin on 02/01/03 9:46 AM, Monty ([EMAIL PROTECTED]) wrote: Happy New Year everyone! Is the PHP mail() command robust enough to use in a little mailing list app? The app will basically send an HTML or Text e-mail to the member database of about 6,000 people. I'm using RedHat Linux 7.2 with PHP 4.2.2, by the way. I'm concerned I'll bog down my server if I issue the mail() command 6,000 times on our server, but, maybe it won't be a problem? Also, although I'm sending HTML e-mail, I'm not including attachments or inline graphics (only direct hotlinks to graphics on a web server). Will mail() still work okay for this, or do I need to use one of the various PHP e-mail classes available to send HTML e-mail? Any recommendations for online tutorials about building a mailing list manager using PHP would be much appreciated! Thanks! Monty -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] using mail() with .info emails?
Im trying to send email using mail() to a .info email address and get an error message. I assume the function parses the email address and doesnt accept anything that isnt the customary .net, .com, etc. addresses. How can I get around this? Thanks joe Popovich _ The new MSN 8: smart spam protection and 3 months FREE*. http://join.msn.com/?page=features/junkmailxAPID=42PS=47575PI=7324DI=7474SU= http://www.hotmail.msn.com/cgi-bin/getmsgHL=1216hotmailtaglines_smartspamprotection_3mf -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] using mail() with .info emails?
On Sunday 29 December 2002 23:45, Joe Popovich wrote: Im trying to send email using mail() to a .info email address and get an error message. I assume the function parses the email address and doesnt accept anything that isnt the customary .net, .com, etc. addresses. How can I get around this? Usually it should work. Maybe a spam-filter from your provider or sth. like that. What kind of error message do you recieve? johannes -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Using Mail Functions.
Dear all, I am a new user on php and I have read on the function of IMAP in the php.net but they made me confuse. In ture i am not understand what is the function and how to use them. Have there got any resource for me to reference? I think that if there got more example it can be more easy to understand. In case, I want to design program which can receive mail and save to mysql server. I have spend so much time on this... :( Can you give me some suggestion? my e-mail: [EMAIL PROTECTED] Best regards, Sidney -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] using mail
Hello, I am using the mail() function right now to send e-mails. Is there a way I can dynamically change where it says the e-mail is from? Thanks Brandon
RE: [PHP] using mail
the forst param to mail is the extra headers to send add in Reply-To: [EMAIL PROTECTED]\r\n and/or From: [EMAIL PROTECTED]\r\n ( I think this one's correct ) -Original Message- From: Brandon Orther [mailto:[EMAIL PROTECTED]] Sent: Tuesday, November 13, 2001 9:41 AM To: PHP User Group Subject: [PHP] using mail Hello, I am using the mail() function right now to send e-mails. Is there a way I can dynamically change where it says the e-mail is from? Thanks Brandon
RE: [PHP] using mail
oops, forst is meant to be forth -Original Message- From: Martin Towell [mailto:[EMAIL PROTECTED]] Sent: Tuesday, November 13, 2001 9:44 AM To: 'Brandon Orther'; PHP User Group Subject: RE: [PHP] using mail the forst param to mail is the extra headers to send add in Reply-To: [EMAIL PROTECTED]\r\n and/or From: [EMAIL PROTECTED]\r\n ( I think this one's correct ) -Original Message- From: Brandon Orther [mailto:[EMAIL PROTECTED]] Sent: Tuesday, November 13, 2001 9:41 AM To: PHP User Group Subject: [PHP] using mail Hello, I am using the mail() function right now to send e-mails. Is there a way I can dynamically change where it says the e-mail is from? Thanks Brandon
Re: [PHP] using mail
Did you RTFM? http://www.php.net/manual/en/function.mail.php Just create a variable and input it as an extra header. $from = from: [EMAIL PROTECTED]\r\n ; mail($to,$subject,$message,$from); On Monday 12 November 2001 02:41 pm, you wrote: Hello, I am using the mail() function right now to send e-mails. Is there a way I can dynamically change where it says the e-mail is from? Thanks Brandon -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
RE: [PHP] using mail
YES I DID READ THE F...in MANUAL -Original Message- From: Kurt Lieber [mailto:[EMAIL PROTECTED]] Sent: Monday, November 12, 2001 2:56 PM To: [EMAIL PROTECTED] Subject: Re: [PHP] using mail Did you RTFM? http://www.php.net/manual/en/function.mail.php Just create a variable and input it as an extra header. $from = from: [EMAIL PROTECTED]\r\n ; mail($to,$subject,$message,$from); On Monday 12 November 2001 02:41 pm, you wrote: Hello, I am using the mail() function right now to send e-mails. Is there a way I can dynamically change where it says the e-mail is from? Thanks Brandon -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
RE: [PHP] using mail
Then why didn't you notice that in the additional headers you can specify the from header? mail([EMAIL PROTECTED], Whee, Whee! Mail Body, From: Jason Murray [EMAIL PROTECTED]\n); Jason -- Jason Murray [EMAIL PROTECTED] Web Developer, Melbourne IT Work now, freak later! -Original Message- From: Brandon Orther [mailto:[EMAIL PROTECTED]] Sent: Tuesday, November 13, 2001 9:52 AM To: PHP User Group Subject: RE: [PHP] using mail YES I DID READ THE F...in MANUAL -Original Message- From: Kurt Lieber [mailto:[EMAIL PROTECTED]] Sent: Monday, November 12, 2001 2:56 PM To: [EMAIL PROTECTED] Subject: Re: [PHP] using mail Did you RTFM? http://www.php.net/manual/en/function.mail.php Just create a variable and input it as an extra header. $from = from: [EMAIL PROTECTED]\r\n ; mail($to,$subject,$message,$from); On Monday 12 November 2001 02:41 pm, you wrote: Hello, I am using the mail() function right now to send e-mails. Is there a way I can dynamically change where it says the e-mail is from? Thanks Brandon -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]