remove_theme_mods
Remove theme modifications option for current theme.
Description
remove_theme_mods();
Usage
if ( !function_exists( 'remove_theme_mods' ) ) { require_once ABSPATH . WPINC . '/theme.php'; } // NOTICE! Understand what this does before running. $result = remove_theme_mods();
Defined (1)
The function is defined in the following location(s).
- /wp-includes/theme.php
- function remove_theme_mods() {
- delete_option( 'theme_mods_' . get_option( 'stylesheet' ) );
- // Old style.
- $theme_name = get_option( 'current_theme' );
- if ( false === $theme_name )
- $theme_name = wp_get_theme()->get('Name');
- delete_option( 'mods_' . $theme_name );
- }