Hiya,
    I have nearly finished a project I am working on, and completely forgot about 
having a newsletter service! Basically its a website, and on the registration page 
people opt in or out of the newsletter, and this is a field in the database.

    So either once a week, or randomly I want to be able to send a newsletter to about 
a million people (hopefully if all goes to plan). 

    What I did envisage was running a PHP script through the command line, which got 
the first 100 or so which wanted the newsletter, then the next 100 etc, till all the 
users who wanted the newsletter got it. Now my Linux is a bit hazy, but I think I can 
run this low priority, because Iam not bothered if it will take a day or so to send 
them all.

    Sommat like this:

    1-     Read the first 100 emails that want the newsletter
    
    2-     Email them

    3- If read 100, then go to 1 (but start from 100), if not quit

    So basically my questions are:

        1- Is this the best way? Or should I use some mailing list software? I do want 
them to subsribe/unsubsribe through the website

        2- Is there a point when the script would time out? I know in Apache, u can 
set a time limit for a script, but would a command line PHP script have the same 
problem? Ihave never run PHP through the command line. 

     Thanks a lot, any advive or links would be great...

    Oh yeh nearly forgot, although it will be hosted on Linux, it will be tested on 
Windows 2k, so hopefully the mehtod would work for Win 2k but this is not necessary...

    Steve

PS I have looked at a few archives, and searched the net but not seen anything that 
helpful... 

Reply via email to