remove_theme_mods

函数


remove_theme_mods ( No parameters )
定义位置
  • wp-includes/theme.php
    , line 1103
引入
2.1.0
弃用

Removes theme modifications option for the active theme.

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 );
}