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.
This hook occurs 2 times in this file.
Line | Code |
---|---|
593 | $theme_loc = 'wp-content/themes'; |
594 | $theme_root = ABSPATH . $theme_loc; |
595 |
|
596 | $template = get_settings('template'); |
597 | $stylesheet = get_settings('stylesheet'); |
598 |
|
599 | if (($template != 'default') && (! file_exists("$theme_root/$template/index.php"))) { |
600 | update_option('template', 'default'); |
601 | update_option('stylesheet', 'default'); |
602 | do_action('switch_theme', 'Default'); |
603 | return false; |
604 | } |
605 |
|
606 | if (($stylesheet != 'default') && (! file_exists("$theme_root/$stylesheet/style.css"))) { |
607 | update_option('template', 'default'); |
608 | update_option('stylesheet', 'default'); |
609 | do_action('switch_theme', 'Default'); |
610 | return false; |
611 | } |
612 |
|
613 | return true; |
614 | } |
615 |
|
616 | function get_broken_themes() { |
617 | global $wp_broken_themes; |
618 |
|