Changeset 18632 for trunk/wp-admin/includes/class-wp-filesystem-base.php
- Timestamp:
- 09/03/2011 02:18:10 PM (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-admin/includes/class-wp-filesystem-base.php
r18268 r18632 154 154 return trailingslashit(constant($constant)); 155 155 } elseif ( 'direct' == $this->method ) { 156 $folder = str_replace('\\', '/', $folder); //Windows path saniti ation156 $folder = str_replace('\\', '/', $folder); //Windows path sanitisation 157 157 return trailingslashit($folder); 158 158 } 159 159 160 $folder = preg_replace('|^([a-z]{1}):|i', '', $folder); //Strip out windows drive letter if its there.161 $folder = str_replace('\\', '/', $folder); //Windows path saniti ation160 $folder = preg_replace('|^([a-z]{1}):|i', '', $folder); //Strip out windows drive letter if it's there. 161 $folder = str_replace('\\', '/', $folder); //Windows path sanitisation 162 162 163 163 if ( isset($this->cache[ $folder ] ) ) … … 224 224 if ( $loop ) 225 225 return false; //Prevent this function from looping again. 226 //As an extra last resort, Change back to / if the folder wasn t found. This comes into effect when the CWD is /home/user/ but WP is at /var/www/.... mainly dedicated setups.226 //As an extra last resort, Change back to / if the folder wasn't found. This comes into effect when the CWD is /home/user/ but WP is at /var/www/.... mainly dedicated setups. 227 227 return $this->search_for_folder($folder, '/', true); 228 228
Note: See TracChangeset
for help on using the changeset viewer.