TalkPHP

TalkPHP (http://www.talkphp.com/forums.php)
-   Tips & Tricks (http://www.talkphp.com/tips-tricks/)
-   -   Tips for sending large number of emails with php (http://www.talkphp.com/tips-tricks/5202-tips-sending-large-number-emails-php.html)

pipesportugal 01-01-2010 10:49 PM

Tips for sending large number of emails with php
 
Hello dear colleagues from talkPHP forum,

After sometime making routines with php I am now at the point of having the need to integrate with some of my routines the capability of sending large volume of emails (like newsletters) to people that are signed on the reserved area of our company.

I know that there are many (also free) software php tools to perform this task, but I want to do it myself and also learn the tricks of doing it.

The first problem to arrise was the fact that the host provider limits the sending of emails to a maximum very low quantity per hour.

So my request with this thread was for the programmers signed up in this forum to give their suggestions of how to overpass this server quantity limitation.

Let's imagine the following situation:
a) I need the send 3.000 newsletter emails.
b) The maximum server quantity would be for example of 200 emails per hour.

My first suggestion would be to create a cron job running at each 30 minutes sending 5 emails with 20 addresses at Bcc.
This would take 15hours to send the full 3.000 emails.

I would like to hear here at the talkphp forum some other suggestions for doing this job with the above numbers/limitations.

A fantastic 2010 to all,
pipesportugal

Village Idiot 01-02-2010 11:09 PM

You are at the mercy of your host, they monitor the mail ports so there are no alternate ways around this. If you need to send this many emails, get a different host. Dedicated is really the best way to because you can choose everything for yourself.

delayedinsanity 01-02-2010 11:59 PM

Quote:

Dedicated is really the best way
I think what he meant to say is VPS. Dedicated is ridiculously expensive, with very little benefit over VPS unless you're running an extremely large site. Check out Linode, or prgmr.com, both are excellent providers.





Village Idiot 01-03-2010 02:45 AM

Quote:

Originally Posted by delayedinsanity (Post 29655)
[font=&quot]

I think what he meant to say is VPS. Dedicated is ridiculously expensive, with very little benefit over VPS unless you're running an extremely large site. Check out Linode, or prgmr.com, both are excellent providers.

VPS can be a worthwhile switch, but I've actually never worked with it though so its not the first thing that comes to my mind. At work we have a number of servers both at a colocation site and in our buildings (the local ones are for internal uses).

delayedinsanity 01-03-2010 03:51 AM

It's a great solution for those of us running our own. Despite being a shared environment, I've yet to come across a situation that's been detrimental to the reliability of any of my servers (running seperate web, database and email).

Arguably the best feature is the low barrier to entry - VPS are relatively cheap for the type of hardware you get at your disposal.

Rhinos 02-28-2010 08:29 PM

If you cannot move to a dedicated server or VPS then the way you suggested is okay, however you have to be aware that if you try and do the limit each hour any other emails that your application may send out will count towards your hourly limit. So if you use emails to send out confirmation emails for registration or with the members randomly generated password then you need to rethink how many you send out each hour.

clonepal 05-20-2011 09:02 PM

We had a client that wanted us to build a script that sends emails, but the only problem it was his hosting didn't allowed him to send more than 100 emails per hours.

So we build him a script in PHP that send only 100 emails per hour. Without the need of a cron to run from cpanel.

-clonepal

pipesportugal 05-20-2011 09:16 PM

Hello clonepal,

Can You be more specific and help Your talkphp colleagues ?

PP

clonepal 05-20-2011 09:24 PM

Hello pipesportugal,

Yes, sure.

My client was having his website hosted on a shared server and the terms and conditions from that hosting company where not to send more that 100 emails per hour.

And my tip for talkphp members is that, if you are on a shared hosting, don't use a script that will send thousands of emails or you will get blacklisted or even banned.

-clonepal

pipesportugal 05-21-2011 12:47 PM

Clonepal,

You are not bringing anything new to the table.

I am using cron job to perform the task...

You are not using cron job.
I haven't seen the tip yet.

Regards
PP

clonepal 05-21-2011 11:36 PM

People should know that a cron job can get you blacklisted for SPAM. Before using any cron jobs for sending emails, people should ask their hosting and ask them what are the limit of sending emails!
This is the point i wanted to tell about, and advice members.

best regards,
clonepal

pipesportugal 05-22-2011 09:02 AM

ok.

There is still another option for programming people that need the ability of send large number of emails, on their programs.

There are service providers for this task where You can make it through API, for a small monthly amount.

There must be many others, but I am leaving here one:

http://www.emailbrain.com/api/documentation/

No publicity intended.

regards,
PP

AxelG 02-18-2012 08:17 PM

There is a solution using a javascript on the page sending the emails. If you are allowed to send 200 emails hour do a script sending a request every 18 secondes. It is not difficult with jQuery. The page must stay open in your navigator during the process.


All times are GMT. The time now is 12:27 PM.

Powered by vBulletin® Version 3.6.8
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.1.0