小编dis*_*Guy的帖子

phpMailer 在给定时间后不会超时

$mailer = new SMTP;    
$mailer->Timeout = 5;    
$mailer->connect($host, $port)    
Run Code Online (Sandbox Code Playgroud)

这应该会在 5 秒后取消 connect(),但超时时间要长得多,并且不会在 5 秒后取消。

如何强制我的脚本在 5 秒后停止尝试连接到 SMTP?

我期待您的答复。

此致,

心烦意乱的家伙

php timeout phpmailer

4
推荐指数
1
解决办法
1165
查看次数

标签 统计

php ×1

phpmailer ×1

timeout ×1