Changeset 5472
- Timestamp:
- 12/09/2011 04:49:04 PM (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/bp-core/bp-core-component.php
r5148 r5472 174 174 return; 175 175 176 $slashed_path = trailingslashit( $this->path ); 177 176 178 // Loop through files to be included 177 179 foreach ( $includes as $file ) { 178 180 179 // Check path + file 180 if ( @is_file( $this->path . '/' . $file ) ) 181 require( $this->path . '/' . $file ); 182 183 // Check path + /bp-component/ + file 184 elseif ( @is_file( $this->path . '/bp-' . $this->id . '/' . $file ) ) 185 require( $this->path . '/bp-' . $this->id . '/' . $file ); 186 187 // Check buddypress/bp-component/bp-component-$file.php 188 elseif ( @is_file( $this->path . '/bp-' . $this->id . '/bp-' . $this->id . '-' . $file . '.php' ) ) 189 require( $this->path . '/bp-' . $this->id . '/bp-' . $this->id . '-' . $file . '.php' ); 190 181 $paths = array( 182 183 // Passed with no extension 184 'bp-' . $this->id . '/bp-' . $this->id . '-' . $file . '.php', 185 'bp-' . $this->id . '-' . $file . '.php', 186 'bp-' . $this->id . '/' . $file . '.php', 187 188 // Passed with extension 189 $file, 190 'bp-' . $this->id . '-' . $file, 191 'bp-' . $this->id . '/' . $file, 192 ); 193 194 foreach ( $paths as $path ) { 195 if ( @is_file( $slashed_path . $path ) ) { 196 require( $slashed_path . $path ); 197 continue; 198 } 199 } 191 200 } 192 201
Note: See TracChangeset
for help on using the changeset viewer.