Changeset 12997 for trunk/wp-admin/includes/class-wp-filesystem-ftpext.php
- Timestamp:
- 02/07/2010 01:12:29 AM (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-admin/includes/class-wp-filesystem-ftpext.php
r12733 r12997 155 155 } 156 156 157 if ( ! $recursive || ! $this->is_dir($file) ) {158 if ( ! function_exists('ftp_chmod') )159 return @ftp_site($this->link, sprintf('CHMOD %o %s', $mode, $file));160 return @ftp_chmod($this->link, $mode, $file);161 }162 //Is a directory, and we want recursive163 $filelist = $this->dirlist($file); 164 foreach ( $filelist as $filename ) {165 $this->chmod($file . '/' . $filename, $mode, $recursive);166 }167 return true;157 // chmod any sub-objects if recursive. 158 if ( $recursive && $this->is_dir($file) ) { 159 $filelist = $this->dirlist($file); 160 foreach ( (array)$filelist as $filename => $filemeta ) 161 $this->chmod($file . '/' . $filename, $mode, $recursive); 162 } 163 164 // chmod the file or directory 165 if ( ! function_exists('ftp_chmod') ) 166 return @ftp_site($this->link, sprintf('CHMOD %o %s', $mode, $file)); 167 return @ftp_chmod($this->link, $mode, $file); 168 168 } 169 169 function chown($file, $owner, $recursive = false ) {
Note: See TracChangeset
for help on using the changeset viewer.