发送错误提示:
SMTP Error: Could not connect to SMTP host. Mailer Error ([email protected]) SMTP Error: Could not connect to SMTP host.
本地测试正常  上传到服务器上就出错了  
当我把类中的函数
public function IsSMTP() 
{
    $this->Mailer = 'smtp';  //改成 $this->Mailer = 'SMTP'; 就可以发送 但是发送的邮件标题重复 并且被当做垃圾邮件处理 
}怎么解决 ??  

解决方案 »

  1.   

    更改phpmailer 的 class.stmp.php文件:$this->smtp_conn = @fsockopen( $host,    // the host of the server
                                      $port,    // the port to use
                                      $errno,   // error number if any
                                      $errstr,  // error message if any
                                      $tval);   // give up after ? secs
    改为
    $this->smtp_conn = @stream_socket_client( $host.':'.$port,    // the host of the server
                            $errno,   // error number if any
                            $errstr,  // error message if any
                            $tval);   // give up after ? secs