Page 1 of 1

sending emails

Posted: Mon Mar 28, 2005 6:45 pm
by dannymc1983
i have written a script that allows someone to send multiple emails at a given time. say for example if you had a list of users registered to a webiste and if you wanted to send them all the same email informing them of something then this script would come in handy. the only thing that im having problems with is that the script is extremely slow to execute!
the script sends a message by connecting to a given SMTP server.

here is some basic pseudocode outlining what i have written:

connect to smtp server;
sendmail to user1;
sendmail to user2;
sendmail to user3;
.
.
.
.
disconnect from server;

also, whenever i try send an email to an address outside of the domain of my smtp server then i get this error message: "550 Relaying is prohibited"
can anyone help me with these problems?

Posted: Mon Mar 28, 2005 6:57 pm
by Pyrite
First of all, check out phpmailer class on sourceforge.

You should use an SMTP server that uses authentication, and then you won't be faced with relaying errors.