You are here: Re: email all users in database help « All PHP « IT news, forums, messages
Re: email all users in database help

Posted by Rik on 02/12/07 11:50

trashed wrote:

Please don't toppost.

> "Rik" <luiheidsgoeroe@hotmail.com> wrote in message
> news:op.tnmu1ya0qnv3q9@misant...
> On Mon, 12 Feb 2007 12:08:45 +0100, trashed <ahhhno@.com> wrote:
>
>> I have a guestbook which has a field that basically asks "join mailing
>> list?". Can someone please point me to a code snippet somewhere that can
>> help me figure out where to start on this? My database (MySQL) already
>> collects all the user's contact info and the 'yes or no' response for
>> the
>> mailing list question so I'm hoping this is not incredibly difficult to
>> do.
>> I have a contact form on my site so maybe I can copy/paste that code for
>> the
>> actual mass mailing function?

This is really all there is to it (aside from maybe setting some headers
for the reply-to adress etc.). How it would be integrated on your site is
totally dependant on the code of your site, I cannot see that from here.

> Also Rik , you provided 2 examples. What is the difference? Why would
> there
> be two possibilities?

The 2 possibilities I gave were:
- Send a seperate email to everyone in the list.
- Send 1 e-mail, with everyone in the bcc.

The first has the advantage of making 'personalised' emails possible,
using your users name etc., and it will less likely be considerd spam.

The second will ease the load on the server, as there's only 1 mail sent,
but could be considered spam by some filters.

For more examples using the function check the manual (and don't forget
the user contributed notes, often a wealth of information):
<http://nl2.php.net/manual/en/function.mail.php>

For more 'advanced' emails you might consider using the PEAR class:
http://pear.php.net/package/Mail

--
Rik Wasmus

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация