如题所述
加到exit(‘注册成功’);那里可以下载个phpmailer下面一个testdemo,你可以试试!IsSMTP();//设置mailer使用smtp模式$mail->Host=$host;//smtp服务器$mail->SMTPAuth=true;//转换成smtp模式$mail->Username=$username;//smtp用户$mail->Password=$password;//smtp密码$mail->From=$username;//发送邮件的邮箱$mail->FromName=$fromname;//发送邮件的用户名$mail->Mailer="smtp";//$mail->IsHTML(true);$mail->Subject=$title;//标题$mail->Body=$content;//发送内容$mail->AltBody=$body;if($addresses){if(is_array($addresses)){foreach($addressesas$address){$mail->AddAddress($address,'');if(!$mail->Send()){echo"Messagecouldnotbesent.";echo"MailerError:".$mail->ErrorInfo;exit;}echo"Messagehasbeensent";}}else{$mail->AddAddress($addresses,"");if(!$mail->Send()){echo"Messagecouldnotbesent.";echo"MailerError:".$mail->ErrorInfo;exit;}echo"Messagehasbeensent";}}}$array=array('231817281@qq.com','2224005116@qq.com');PHPsendMail('2224005116@qq.com','80300838397','smtp.qq.com','762591150@qq.com','abc','abc','亲爱哒!!','bbbbb');
温馨提示:答案为网友推荐,仅供参考