OK OK, when I run this script, then I connect to 3 separate IPs.
The directory and download them to the website.
I have a problem with two of them ...
I have disabled the FTP but it is still coming back as bool (false) Updating Server 1 Bull (false) Warning: ftp_get () [function.ftp-get]: File name can not be blank in Recorder 42 Warning: ftp_get () [Function. Ftp-get]: Error opening updater.php on line 42 ... Updated cache ... bool (false) Warning: ftp_get () [function.ftp-get]: file name in line in updater.php Not empty 60 WARNING: ftp_get () [function.ftp-get]: Error opening updater.php on line 60 BZh9rE8PUpdated map ... Server 2 Bull Update (wrong) Warning: ftp_get () [function.ftp-get]: file Can not name 103 be empty in updater.php in line on Warning: ftp_get () [function.ftp-get]: Error 103. Up to date 103. Opening in updater.php dated cache ... Bull (false ) Warning: ftp_get () [function.ftp-get]: File name may not be blank on line in updater.php 121 Warning: ftp_get () [function.ftp-get]: .php line 121 BZh9rE8PUpdated map ... server Update 3 Array (1) {[0] = & gt; String (36) "1ba90fa2e972b50cdaa6bb23c403296b.dua"} Cache Update ... array (8) {[0] = & gt; String (6) "graph" [1] = & gt; String (22) "sb_Forlorn_sb3_R2L.bsp" [2] = & gt; String (17) "sb_gooniverse.bsp" [3] = & gt; String (22) "sb_lostinspace_rc5.bsp" [4] = & gt; String (19) "sb_new_worlds_2.bsp" [5] = & gt; String (22) "sb_Spacewar_SB3_V1.bsp" [6] = & gt; String (21) "sb_twinsuns_fixed.bsp" [7] = & gt; String (10) "soundtrack"} updated the map ...
Part of the script:
ftp_pasv ($ conn, true); Ftp_chdir ($ cone, "$ DIR / map /"); $ Files = ftp_nlist ($ conn, "*. *"); Var_dump ($ files); Chdir ('sandbox / cache /'); ($ I = 0; $ i & lt; Count ($ files); $ i ++) {if (! Ftp_is_dir ($ files [$ i])) {Sleep (500000); If (! File_exists ($ files [$ i])) {ftp_get ($ conn, $ files [$ i], $ files [$ i], FTP_ASCII); }}} Resonant "update cache ...
";
You can not use ftp_nlist () correctly Are there.
Specifies the second argument to be a directory name (represented by a string) It seems that you are trying to denote a filename pattern instead.
Using your code:
$ files = ftp_nlist ($ conn, "*. *"); Unless you have *. * is not a directory named, it will not work.
You'll be able to *. * with the valid directory name relative to the FTP user's home directory.
For example:
$ files = ftp_nlist ($ conn, "."); Will list the files in the current directory, which is likely to be $ DIR / maps / in relation to your code.
In order to deal with firewall problems among hosts, you may have to switch to FTP disable mode so that your script is running and the FTP host. See for details.
Comments
Post a Comment