Changeset 41928
- Timestamp:
- 10/18/2017 09:27:22 PM (7 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-admin/includes/misc.php
r41851 r41928 68 68 $result = array (); 69 69 70 if ( !file_exists( $filename ) ) {70 if ( ! file_exists( $filename ) ) { 71 71 return $result; 72 72 } 73 73 74 if ( $markerdata = explode( "\n", implode( '', file( $filename ) ) ));75 { 76 77 78 if (strpos($markerline, '# END ' . $marker) !== false)79 80 if ( $state ) 74 $markerdata = explode( "\n", implode( '', file( $filename ) ) ); 75 76 $state = false; 77 foreach ( $markerdata as $markerline ) { 78 if ( false !== strpos( $markerline, '# END ' . $marker ) ) { 79 $state = false; 80 if ( $state ) { 81 81 $result[] = $markerline; 82 if (strpos($markerline, '# BEGIN ' . $marker) !== false) 82 } 83 if ( false !== strpos( $markerline, '# BEGIN ' . $marker ) ) { 83 84 $state = true; 85 } 84 86 } 85 87 }
Note: See TracChangeset
for help on using the changeset viewer.