Example #1
0
function themify_config_init()
{
    /* 	Set Error Reporting
     ***************************************************************************/
    if (defined('WP_DEBUG') && WP_DEBUG) {
        error_reporting(E_ERROR | E_WARNING | E_PARSE);
    } else {
        error_reporting(E_ERROR);
    }
    /* 	Global Vars
     ***************************************************************************/
    global $themify_config, $pagenow, $ThemifyConfig, $themify_gfonts;
    /*	Activate Theme
     ***************************************************************************/
    if (isset($_GET['activated']) && 'themes.php' == $pagenow) {
        themify_maybe_unset_image_script();
        themify_maybe_clear_legacy();
        header('Location: ' . admin_url() . 'admin.php?page=themify&firsttime=true');
    }
    /* 	Theme Config
     ***************************************************************************/
    define('THEMIFY_VERSION', '1.6.4');
    /*	Load Config from theme-config.php or custom-config.php
     ***************************************************************************/
    $themify_config = $ThemifyConfig->get_config();
    /* 	Google Fonts
     ***************************************************************************/
    $themify_gfonts = themify_get_google_font_lists();
    /* 	Woocommerce
     ***************************************************************************/
    if (themify_is_woocommerce_active()) {
        add_theme_support('woocommerce');
    }
}
function themify_config_init()
{
    /* 	Global Vars
     ***************************************************************************/
    global $themify_config, $pagenow, $ThemifyConfig, $themify_gfonts;
    /*	Activate Theme
     ***************************************************************************/
    if (isset($_GET['activated']) && 'themes.php' == $pagenow) {
        themify_maybe_clear_legacy();
        add_action('init', 'themify_theme_first_run', 20);
    }
    /* 	Theme Config
     ***************************************************************************/
    define('THEMIFY_VERSION', '2.2.7');
    /*	Load Config from theme-config.php or custom-config.php
     ***************************************************************************/
    $themify_config = $ThemifyConfig->get_config();
    /* 	Google Fonts
     ***************************************************************************/
    $themify_gfonts = themify_get_google_font_lists();
    /* 	Run after update
     ***************************************************************************/
    if ('update_ok' === get_option('themify_update_ok_flag')) {
        /**
         * Fires after the updater finished the updating process.
         *
         * @since 1.8.3
         */
        do_action('themify_updater_post_install');
    }
    /* 	Woocommerce
     ***************************************************************************/
    if (themify_is_woocommerce_active()) {
        add_theme_support('woocommerce');
    }
    /**
     * Editor Style
     * @since 2.0.2
     */
    add_editor_style();
    /**
     * Do not add custom background
     * @since 2.0.2
     */
    if (false) {
        add_theme_support('custom-background');
        add_theme_support('custom-header');
    }
}
function themify_config_init()
{
    /* 	Set Error Reporting
     ***************************************************************************/
    if (defined('WP_DEBUG') && WP_DEBUG) {
        error_reporting(E_ERROR | E_WARNING | E_PARSE);
    } else {
        error_reporting(E_ERROR);
    }
    /* 	Global Vars
     ***************************************************************************/
    global $themify_config, $pagenow, $ThemifyConfig, $themify_gfonts;
    /*	Activate Theme
     ***************************************************************************/
    if (isset($_GET['activated']) && 'themes.php' == $pagenow) {
        themify_maybe_clear_legacy();
        add_action('init', 'themify_theme_first_run', 20);
    }
    /* 	Theme Config
     ***************************************************************************/
    define('THEMIFY_VERSION', '1.9.9');
    /*	Load Config from theme-config.php or custom-config.php
     ***************************************************************************/
    $themify_config = $ThemifyConfig->get_config();
    /* 	Google Fonts
     ***************************************************************************/
    $themify_gfonts = themify_get_google_font_lists();
    /* 	Run after update
     ***************************************************************************/
    if ('update_ok' === get_option('themify_update_ok_flag')) {
        /**
         * Fires after the updater finished the updating process.
         *
         * @since 1.8.3
         */
        do_action('themify_updater_post_install');
    }
    /* 	Woocommerce
     ***************************************************************************/
    if (themify_is_woocommerce_active()) {
        add_theme_support('woocommerce');
    }
}