WP hooks navigation: Home/browse • Actions index • Filters index
To save our bandwidth, we show only a snippet of code around each occurence of the hook. View complete file in SVN (without highlighting).
The best way to understand what a hook does is to look at where it occurs in the source code.
do_action( "hook_name" )apply_filters( "hook_name", "what_to_filter" ).Remember, this hook may occur in more than one file. Moreover, the hook's context may change from version to version.
| Line | Code |
|---|---|
| 464 | </fieldset> |
| 465 | <?php |
| 466 | } |
| 467 | |
| 468 | function check_admin_referer() { |
| 469 | $adminurl = strtolower( get_settings('siteurl') ) . '/wp-admin'; |
| 470 | $referer = strtolower( $_SERVER['HTTP_REFERER'] ); |
| 471 | if ( !strstr($referer, $adminurl) ) |
| 472 | die(__('Sorry, you need to <a href="http://codex.wordpress.org/Enable_Sending_Referrers">enable sending referrers</a> for this feature to work.')); |
| 473 | do_action('check_admin_referer'); |
| 474 | } |
| 475 | |
| 476 | // insert_with_markers: Owen Winkler |
| 477 | // Inserts an array of strings into a file (.htaccess), placing it between |
| 478 | // BEGIN and END markers. Replaces existing marked info. Retains surrounding |
| 479 | // data. Creates file if none exists. |
| 480 | // Returns true on write success, false on failure. |
| 481 | function insert_with_markers($filename, $marker, $insertion) { |
| 482 | if (!file_exists($filename) || is_writeable($filename)) { |