|
|
|
|
Using Loops to Send Mail to Multiple Recipients
Home » PHP » Mailing List Management
Using Loops to Send Mail to Multiple Recipients
This tutorial with revised code shows you how to send email to multiple recipients using loops.
The admin code I created worked fine except for one bothersome thing. It would send out the email to multiple recipients and print the proper unsubscribe code, BUT the "From" mail header did not work the way it should have inside of the "all" loop. It should have been printing my from email address on every email address, however it was printing "nobody" instead. When I send the emails to any single person the header it printed correctly. Do you know what I was doing wrong? Read on and I'll explain.
The Admin PHP code for the mail list script
Yesterday we did the HTML form and I realized while re-reading my diary entry I neglected to explain the "test" email and its use. You could set up an email and then mail to the "test" email first (you, namely). It is pretty good idea to run a test mail to see how things look before actually sending the email to multiple recipients. Unfortunately we are in a spam-filled cyber world these days. Let's look at the entire admin code to send the mail to multiple recipients. It is quite similar to the loop yesterday which filled the dynamic dropdown select menu:
|
More Tutorials by this user
|
|
|
|
|
|
|
|
|