Solved

sending newsletters via php & mysqld

Posted on 2011-03-16
4
173 Views
Last Modified: 2012-08-13
Hi,
I have a script for sending newsletters.

my ISP has advised me to set a sleep command of 10seconds every 50 emalis so as to batch them and avoid a few issues.

I'm findng this can lock the browser

One suiggestion
Create a cronjob that runs every 30 mins
It searches a database for newslettter requests
After executing the script to send newsletters,  it deletes the records

In my script, I'd create the record with any variables before returning control to my browser
then wait for the cronjob

Can anyone highllight issues with this approach and/or offer better options
thanks
0
Comment
Question by:joomla
  • 2
4 Comments
 
LVL 34

Expert Comment

by:Beverley Portlock
ID: 35148083
Your basic approach is correct, but I would add these comments

1) If anything goes wrong it sounds like your ISP will not be best pleased. You may breach the Acceptable Use Policy

2) Use ConstantContact or GraphicMail. They will both do this job for you and the statistical analysis tools are good. The emails are very cheap to send. Both companies offer demo accounts for free.

These companies have already solved the email campaign as a problem and they are very, very cost effective. Don't waste your valuable time reinventing the wheel and trying to save a few pennies.
0
 
LVL 14

Accepted Solution

by:
EMB01 earned 250 total points
ID: 35148349
Instead of deleting newsletters after it send them, just add another field called "sent" and update the records once they are sent.  When you send you newsletters, only records that have not yet been sent will be sent.  I created a mass mailer and it worked very well, and it didn't cost me anything but hosting and my time.  I had a pretty good click-through rate, too.
0
 

Author Comment

by:joomla
ID: 35169744
thanks for your feedback EMB01
not sure it's worth 250 points.
Are there any limitations you can think of or spam guidelines I need to consider

Will cronjob set to 30mins be too resource intensive?
htnaks
0
 
LVL 14

Expert Comment

by:EMB01
ID: 37680014
>>  not sure it's worth 250 points.

Thanks, buddy!

>>  Are there any limitations you can think of or spam guidelines I need to consider

Check the SPF and domain keys for your sending IP.

Will cronjob set to 30mins be too resource intensive?

>>  Depends on your server requirements.  The server I sent from didn't have much traffic, so I maxed her out when sending emails.
0

Featured Post

3 Use Cases for Connected Systems

Our Dev teams are like yours. They’re continually cranking out code for new features/bugs fixes, testing, deploying, testing some more, responding to production monitoring events and more. It’s complex. So, we thought you’d like to see what’s working for us.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Popularity Can Be Measured Sometimes we deal with questions of popularity, and we need a way to collect opinions from our clients.  This article shows a simple teaching example of how we might elect a favorite color by letting our clients vote for …
This article discusses four methods for overlaying images in a container on a web page
Learn how to match and substitute tagged data using PHP regular expressions. Demonstrated on Windows 7, but also applies to other operating systems. Demonstrated technique applies to PHP (all versions) and Firefox, but very similar techniques will w…
The viewer will learn how to dynamically set the form action using jQuery.

919 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now