RE: [PHP-DB] Emailing a Database

From: Date: Tue, 10 Oct 2000 02:10:39 +0000
Subject: RE: [PHP-DB] Emailing a Database
References: 1  Groups: php.db 
Request: Send a blank email to php-db+get-3452@lists.php.net to get a copy of this message
It's been a while, but this is about what I did: (in bash) echo select emailaddress from customers | \ mysql -uuser -ppassword database | \ while read address ; do cat email.txt | sendmail -ffoo@myorg.com $address done Not pretty, but should work very well. Alternatively, you could use the first line to get the email addresses out of the database and into a text file, then use a more conventional method of spamming the list. G'luck, -- Troy Settle Pulaski Networks 540.994.4254 ** -----Original Message----- ** From: Peter Burgess [mailto:peter@m2o.com.au] ** Sent: Monday, October 09, 2000 9:17 PM ** To: php-db@lists.php.net ** Subject: [PHP-DB] Emailing a Database ** ** ** Hi There, ** ** I've created a database of customers and their email addresses ** in mySQL but have no idea how to email all those addresses. ** Could someone point me to some tutorials or render some advice. ** >From reading some resources I know that this can be achieved ** via perl but can php perform this function. Any advice would be ** welcomed. ** ** __,,_____________ ** < ___________/ ** / /-' ** /___/ ** ** Peter Burgess ** m2o Designs ** 151 Greville Street Prahran 3181 ** Melbourne Australia ** Ph: 03 9521 2553 ** Fx: 03 9529 4712 ** EM: peter@m2o.com.au ** URL:http://www.m2o.com.au ** ** **

« previous php.db (#3452) next »