国产 无码 综合区,色欲AV无码国产永久播放,无码天堂亚洲国产AV,国产日韩欧美女同一区二区

phpmailer SMTP ERROR: Failed to connect to server: (0)

報錯信息


SMTP ERROR: Failed to connect to server: (0)
SMTP Error: Could not connect to SMTP host.Failed to connect to server


文章來源地址http://www.zghlxwxcb.cn/article/244.html

解決方案


列舉了多種smtp error的解決方法,總有一種適合你??!

1、忽略ssl認(rèn)證

// 實例化PHPMailer核心類
$mail = new PHPMailer(); 
...
$mail->SMTPOptions = array(
    'ssl' => array(
        'verify_peer' => false,
        'verify_peer_name' => false,
        'allow_self_signed' => true
    )
);
...


2、將端口設(shè)置位25 ,不使用SSL,465

// 設(shè)置使用ssl加密方式登錄鑒權(quán)
$mail->SMTPSecure = 'ssl';
// 設(shè)置ssl連接smtp服務(wù)器的遠(yuǎn)程服務(wù)器端口號
$mail->Port = 465;

改為

$mail->Port = 25;


3、請檢查SMTP服務(wù)器的賬號、密碼是否正確或者查看一下服務(wù)器是否開啟 25端


4、查看網(wǎng)絡(luò)設(shè)置或者防火墻是否阻止了smtp連接,端口之類的


5、嘗試使用不同的加密方式,例如SSL或TLS。


6、如果還是不行,就使用其他的STMP服務(wù)器看看效果,如:QQ,163,Gmail或Outlook等






到此這篇關(guān)于phpmailer SMTP ERROR: Failed to connect to server: (0)的文章就介紹到這了,更多相關(guān)內(nèi)容可以在右上角搜索或繼續(xù)瀏覽下面的相關(guān)文章,希望大家以后多多支持TOY模板網(wǎng)!

原文地址:http://www.zghlxwxcb.cn/article/244.html

如若轉(zhuǎn)載,請注明出處: 如若內(nèi)容造成侵權(quán)/違法違規(guī)/事實不符,請聯(lián)系站長進(jìn)行投訴反饋,一經(jīng)查實,立即刪除!

領(lǐng)支付寶紅包贊助服務(wù)器費(fèi)用
未經(jīng)允許不得轉(zhuǎn)載:Toy模板網(wǎng) » phpmailer SMTP ERROR: Failed to connect to server: (0)

相關(guān)文章

  • 使用SpringBoot + JavaMailSender 發(fā)送郵件報錯 Mail server connection failed;Could not connect to SMTP host

    在 application.yml 中將郵件配置為 SSL 連接 yml 如果你使用的是 properties 文件,應(yīng)該修改為: properties 推薦一個 yml、properties 文件在線轉(zhuǎn)換的網(wǎng)站? 在線yaml轉(zhuǎn)properties-在線properties轉(zhuǎn)yaml-ToYaml.com ? 來源:https://www.cnblogs.com/songjilong/p/12577010.html

    2024年02月04日
    瀏覽(25)
  • Telnet SMTP協(xié)議關(guān)于“535 Error: authentication failed“解決思路

    Telnet SMTP協(xié)議關(guān)于“535 Error: authentication failed“解決思路

    計算機(jī)網(wǎng)絡(luò)中應(yīng)用層的SMTP(Simple Mail Transfer Protocol)協(xié)議可用來發(fā)送郵件,在Telnet使用SMTP登陸賬號密碼時出現(xiàn)“535 Error: authentication failed”問題?,F(xiàn)記錄解決步驟。 1. 確認(rèn)在郵箱中已開啟SMTP服務(wù)。 2.? 按照掃碼流程,獲得 授權(quán)密碼 (一定要保存好), 該授權(quán)密碼是用于登錄第

    2024年02月02日
    瀏覽(20)
  • Oracle ORA-28547:connection to server failed,probable Oracle Net admin error

    Oracle ORA-28547:connection to server failed,probable Oracle Net admin error

    使用Navicat連接oracle數(shù)據(jù)庫時報ORA-28547錯誤 因為Navicat自帶的oci.dll并不支持oracle11g,需要去官網(wǎng)下載支持的版本。 1.去oracle下載對應(yīng)的oci.dll文件 下載地址:Oracle Instant Client Downloads 可以用 11.2.0.4? 2.?復(fù)制剛下載下來的instantclient_11_2文件夾中的所有文件,粘貼到Navicat的instantc

    2024年04月18日
    瀏覽(29)
  • java SMTP郵件發(fā)送,修復(fù)SSL下465端口Could not connect to SMTP

    java SMTP郵件發(fā)送,修復(fù)SSL下465端口Could not connect to SMTP

    起因:開發(fā)郵件發(fā)送系統(tǒng)時,使用25端口能夠正常發(fā)送郵件,啟用SSL使用465端口時,發(fā)送郵件報Could not connect to SMTP host: smtp.qiye.aliyun.com, port: 465的錯誤。 由于25端口可以正常發(fā)送郵件,所以可以保證賬號和網(wǎng)絡(luò)是通的,那么可能就出在465出站權(quán)限或者服務(wù)器環(huán)境問題。 經(jīng)運(yùn)維

    2024年02月02日
    瀏覽(24)
  • Failed to connect to the remote extension host server(Error: WebSocket close with status code 1006)

    Failed to connect to the remote extension host server(Error: WebSocket close with status code 1006)

    解決辦法(第一種情況): 首先,檢查遠(yuǎn)程服務(wù)器上的 /etc/ssh/sshd_config里,有沒有允許端口轉(zhuǎn)發(fā):AllowTcpForwarding yes 更改后,重啟 sshd服務(wù):systemctl restart sshd。 然后,刪除~/.vscode-server目錄 本地Vscode settings的user配置里,把remote.SSH.remoteServerListenOnSocket的勾去掉(因為remote配置那

    2024年02月03日
    瀏覽(29)
  • [Labtools 27-3733] Error during cs_server initialization: Failed to connect cs_server at TCP:localho

    記錄遇到過的問題: [Labtools 27-3733] Error during cs_server initialization: Failed to connect cs_server at TCP:localhost:3042 to hw_server at TCP:localhost:3121. 燒錄程序時,打開硬件目標(biāo)找不到JTAG。 (此鏈接可見詳情)xilinx vivado 2019 驅(qū)動問題,Connecting to hw_server url TCP:localhost:3121,jtag連接不上 | 碼農(nóng)家園

    2024年02月02日
    瀏覽(22)
  • psql: error: connection to server on socket “/var/run/postgresql/.s.PGSQL.5432“ failed: No such file

    當(dāng)我在linux debian版本安裝postgres數(shù)據(jù)庫遇到的問題: 幫我解決成功的方法如下:可以直接復(fù)制運(yùn)行,需要看注釋 步驟一: 步驟二: 注意這里的16是我postgres的版本,你要改成你對應(yīng)的版本數(shù)字比如14就改成14,然后出現(xiàn)語言區(qū)域我一般默認(rèn)直接回車 步驟三: 然后就成功了 引

    2024年02月02日
    瀏覽(16)
  • 解決發(fā)郵件錯誤javax.mail.MessagingException: Could not connect to SMTP host

    用java實現(xiàn)發(fā)送郵件功能時報錯 javax.mail.MessagingException: Could not connect to SMTP host 解決辦法: props.put(“mail.smtp.ssl.enable”, true);

    2024年02月16日
    瀏覽(19)
  • 解決 Burpsuite Error Proxy Failed to connect to www.com

    解決 Burpsuite Error Proxy Failed to connect to www.com

    我的環(huán)境: win10,Burpsuite 2022 個人覺得 Burpsuite版本對此報錯是沒有影響的。 之前不知道從什么時候開始 Burpsuite 就一直出現(xiàn)這個問題。 發(fā)現(xiàn)所有國內(nèi)的網(wǎng)站都可以訪問,但是外網(wǎng)的全部都會 443。報錯截圖如圖所示 一直沒找到辦法,Burp 官網(wǎng)論壇上說的是防火墻的問題,其實

    2024年02月13日
    瀏覽(34)
  • WebSocket connection to failed: Error in connection establishment: net::ERR_CONNECTION_REFUSED

    WebSocket connection to failed: Error in connection establishment: net::ERR_CONNECTION_REFUSED

    1.先查是否開啟了socket端口 2.需要配置 你得nginx ws://域名/wss(可自定義) nginx 配置

    2024年02月08日
    瀏覽(19)

覺得文章有用就打賞一下文章作者

支付寶掃一掃打賞

博客贊助

微信掃一掃打賞

請作者喝杯咖啡吧~博客贊助

支付寶掃一掃領(lǐng)取紅包,優(yōu)惠每天領(lǐng)

二維碼1

領(lǐng)取紅包

二維碼2

領(lǐng)紅包