validate_current_theme
Filter HookDescription
Filters whether to validate the active theme.Hook Information
File Location |
wp-includes/theme.php
View on GitHub
|
Hook Type | Filter |
Line Number | 909 |
Hook Parameters
Type | Name | Description |
---|---|---|
bool
|
$validate
|
Whether to validate the active theme. Default true. |
Usage Examples
Basic Usage
<?php
// Hook into validate_current_theme
add_filter('validate_current_theme', 'my_custom_filter', 10, 1);
function my_custom_filter($validate) {
// Your custom filtering logic here
return $validate;
}
Source Code Context
wp-includes/theme.php:909
- How this hook is used in WordPress core
<?php
904 *
905 * @since 2.7.0
906 *
907 * @param bool $validate Whether to validate the active theme. Default true.
908 */
909 if ( wp_installing() || ! apply_filters( 'validate_current_theme', true ) ) {
910 return true;
911 }
912
913 if (
914 ! file_exists( get_template_directory() . '/templates/index.html' )
PHP Documentation
<?php
/**
* Filters whether to validate the active theme.
*
* @since 2.7.0
*
* @param bool $validate Whether to validate the active theme. Default true.
*/
Quick Info
- Hook Type: Filter
- Parameters: 1
- File: wp-includes/theme.php
Related Hooks
Related hooks will be displayed here in future updates.