It is worth noting that the mail() function is not suitable for larger volumes of email in a loop.
This function opens and closes an SMTP socket for each email... not very efficient.
To send email using sockets, I suggest reading this:
http://cr.yp.to/smtp.html
I would not recommend using the mail() function in PHP for anything over 100 mails, not even using it by breaking out your recipients in batches of 25, 50, 100 etc. and looping with the function.
The mail function in general is pretty weak - your best option would be to open a socket to SMTP and package up the mail in an env and send it at once by using 'RCPT TO:' in the SMTP connection.
Make your connection by using fsockopen() or popen().
Look through the user notes on fsockopen() and you will see a few examples of sending mail to SMTP using this...
Mark
P.S. Also tak a look at
phpmailer-class