找回密码
 立即注册
搜索
热搜: 活动 交友 discuz

destoon超时多长时间链接不上远程ftp,就保存本地。

[复制链接]
发表于 2020-9-6 22:57:57 | 显示全部楼层 |阅读模式
超时多长时间链接不上远程ftp,就保存本地。


1.  修改/upload.php


2. 找到

  1. if($DT['ftp_remote'] && $DT['remote_url']) {
复制代码
3. 在这上面增加:



  1.   //判断2秒是否能够连接上ftp
  2.   $timeout = @ftp_connect($DT['ftp_host'], $DT['ftp_port'],2);
  3.   if(!$timeout){
  4.   $DT['ftp_remote']=0;  
  5.   }
  6.   //

复制代码


您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

Archiver|手机版|小黑屋|知识在线

GMT+8, 2026-11-2 21:20 , Processed in 0.197392 second(s), 20 queries .

Powered by Discuz! X5.0

© 2001-2026 Discuz! Team.

快速回复 返回顶部 返回列表