Jump to content

Recommended Posts

The idea i had at doing this was:

Example:

<?php

$mailpost = $_POST['mail'];

$allmail = explode(",",$mailpost);

 

for ($i=0; $i<count($allmail); $i++){

mail(); // subject etc.. would be entered but not for this example.

}

?>

 

Can someone tell me or give me an example of where im going wrong... Thanks ;)

Link to comment
https://forums.phpfreaks.com/topic/55261-mailing-multiple-users/
Share on other sites

If I was in your place i did it in this way

<?php
$mail = new mail($_POST['mail'], "Subject", "Mail Body");
//3 Arguments Are Given
//$mail = new mail("to@domain", "Mail Subject", "Mail Body");
if($mail->send())
    {
        echo "Mail Sent Succfully\n";
    }
else 
    {
        echo "Sorry Mail Sending Failed\n";
        print_r($mail->error);//Print The Errors
    }
?>

Class aviliable at

http://zigmoyd.sourceforge.net/man/mail.php#mail

Installation and Instruction on

http://zigmoyd.sourceforge.net/man/index.php

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.