esc_js( $warning ), 'id' => '', ) ); ?>

array(), 'options' => array(), ); foreach ( $theme_mods as $theme_mod ) { if ( 'generate_copyright' === $theme_mod ) { if ( in_array( 'copyright', $_POST['module_group'] ) ) { remove_theme_mod( $theme_mod ); } } else { if ( in_array( 'generate_settings', $_POST['module_group'] ) ) { remove_theme_mod( $theme_mod ); } } } foreach ( $settings as $setting ) { if ( in_array( $setting, $_POST['module_group'] ) ) { delete_option( $setting ); } } // Delete our dynamic CSS option. delete_option( 'generate_dynamic_css_output' ); delete_option( 'generate_dynamic_css_cached_version' ); // Reset our dynamic CSS file updated time so it regenerates. $dynamic_css_data = get_option( 'generatepress_dynamic_css_data', array() ); if ( isset( $dynamic_css_data['updated_time'] ) ) { unset( $dynamic_css_data['updated_time'] ); } update_option( 'generatepress_dynamic_css_data', $dynamic_css_data ); // Delete any GeneratePress Site CSS in Additional CSS. $additional_css = wp_get_custom_css_post(); if ( ! empty( $additional_css ) ) { $additional_css->post_content = preg_replace( '#(/\\* GeneratePress Site CSS \\*/).*?(/\\* End GeneratePress Site CSS \\*/)#s', '', $additional_css->post_content ); wp_update_custom_css_post( $additional_css->post_content ); } wp_safe_redirect( admin_url( 'themes.php?page=generate-options&status=reset' ) ); exit; } add_action( 'admin_head', 'generate_reset_options_css', 100 ); /** * Add CSS to the dashboard. */ function generate_reset_options_css() { $screen = get_current_screen(); if ( ! is_object( $screen ) ) { return; } if ( 'appearance_page_generate-options' !== $screen->base ) { return; } ?> base ) { return; } ?>