i have test web page (see below) has single instruction displays happy_face.gif image. image source address in test page refers php script file (see below) returns image , sends email single recipient address. code listed below works fine.
however, when use mozilla thunderbird or outlook 2010 email client , insert picture (using email client’s image link feature) , provide "http://www.example.com/displays_image_&_sends_email.php" link address, , send email single email address (no cc or bcc) following happens: image shown in case of thunderbird php script sends 4 emails instead of one, , when using outlook 2010 sends 12 emails instead of single one.
please help.
thanks, menachem blasberg
http://www.example.com/snipett_displays_image_&_sends_email.html
<img src="http://www.example.com/displays_image_&_sends_email.php" > http://www.example.com/displays_image_&_sends_email.php
<?php // show image in browser client. $logo = "http://www.example.com/happy_face.gif"; // set image full path readfile($logo); // send test email. ini_set( 'display_errors', 1 ); error_reporting( e_all ); $from = "mblasberg@inoxel.com"; $to = "menb@pacbell.net"; $subject = "php mail test script"; $message = "this test check php mail functionality"; $headers = "from:" . $from; mail($to,$subject,$message, $headers); ?>
the change need make send multiple emails is,put recipient emails in form of text seperated comma's, , put text in address send email email ids.i.e
$recipients = array( "youremailaddress@yourdomain.com", // more emails ); $email_to = implode(',', $recipients); // email address
Comments
Post a Comment