extract_from_markers [ WordPress Function ]
extract_from_markers ( $filename, $marker )
| Parameters: |
|
| Returns: |
|
| Defined at: |
|
Benzer Fonksiyonlar: insert_with_markers, get_gmt_from_date, get_date_from_gmt, get_bookmarks, get_column_headers
{@internal Missing Short Description}}
Source
<?php
function extract_from_markers( $filename, $marker ) {
$result = array ();
if (!file_exists( $filename ) ) {
return $result;
}
if ( $markerdata = explode( "\n", implode( '', file( $filename ) ) ));
{
$state = false;
foreach ( $markerdata as $markerline ) {
if (strpos($markerline, '# END ' . $marker) !== false)
$state = false;
if ( $state )
$result[] = $markerline;
if (strpos($markerline, '# BEGIN ' . $marker) !== false)
$state = true;
}
}
return $result;
}
?>
Examples [ wp-snippets.com ]
Google Arama Sonuçlarý
- extract_from_markers | A HitchHackers guide through WordPress
Feb 11, 2011 ... function extract_from_markers( $filename, $marker ) { $result = array (); if (! file_exists( $filename ) ) { return $result; } if ( $markerdata = explode( ...
hitchhackerguide.com - extract_from_markers() WordPress function reference, arguments ...
extract_from_markers(). Signature. extract_from_markers( $filename, $marker ). filename: (unknown_type); marker: (unknown_type). Return. (array) An array of ...
queryposts.com - WordPress › Support » Extract_From_Markers / Insert_With_Markers?
Hi,. I just found these two WP functions within plugins that insert lines into . htaccess or robots.txt and which I find very useful for me: extract_from_markers(); ...
wordpress.org - Docs for page misc.php
array extract_from_markers (unknown_type $filename, unknown_type $marker). unknown_type $filename; unknown_type $marker. got_mod_rewrite (line 16) ...
phpdoc.wordpress.org