Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- /**
- *
- * @ This file is created by http://DeZender.Net
- * @ deZender (PHP7 Decoder for SourceGuardian Encoder)
- *
- * @ Version : 4.1.0.1
- * @ Author : DeZender
- * @ Release on : 29.08.2020
- * @ Official site : http://DeZender.Net
- *
- */
- function zyx_add_wp_enqueue()
- {
- wp_enqueue_style('zyx_style_css', ZY_ZAUTHS_DIR_URL . 'core/assets/css/style.min.css', [], time());
- wp_enqueue_script('zyx_script_js', ZY_ZAUTHS_DIR_URL . 'core/assets/js/main.min.js', ['jquery'], Plugin_Version_zyx_aut('Version'));
- }
- function zyx_get_product_write_aut()
- {
- if (!is_admin() && !!current_user_can('manage_options')) {
- return false;
- }
- global $wpdb;
- if ($_SERVER['REQUEST_METHOD'] === 'POST') {
- $term = (isset($_POST['term']) ? sanitize_text_field($_POST['term']) : '');
- if (!empty($term)) {
- $search_term = (!empty($term) ? $wpdb->esc_like($term) : '');
- if (!empty($search_term)) {
- $query = $wpdb->get_results($wpdb->prepare("\n" . ' SELECT domain ' . "\n" . ' FROM ' . $wpdb->prefix . 'product_aut ' . "\n" . ' WHERE domain LIKE \'%%%s%%\'' . "\n" . ' ORDER BY domain ASC' . "\n" . ' LIMIT 25' . "\n" . ' ', $search_term), ARRAY_A);
- }
- else {
- $query = $wpdb->get_results('SELECT domain FROM ' . $wpdb->prefix . 'product_aut ORDER BY domain ASC LIMIT 25', ARRAY_A);
- }
- if (!is_wp_error($query) && !empty($query)) {
- foreach ($query as $domain_info) {
- $options[$domain_info['domain']] = $domain_info['domain'];
- }
- }
- else {
- $options = '';
- }
- return $options;
- }
- }
- }
- function zyx_custom_product_setup()
- {
- $product_name = (!!zyx_auth('product_display_name') ? zyx_auth('product_display_name') : '产品');
- $product_rewrite_slug = (!!zyx_auth('product_rewrite_slug') ? zyx_auth('product_rewrite_slug') : 'product');
- $product_category_rewrite_slug = '';
- $product_tag_rewrite_slug = '';
- register_post_type('product', [
- 'labels' => ['name' => $product_name, 'singular_name' => $product_name, 'menu_name' => $product_name, 'all_items' => '所有' . $product_name, 'add_new' => '添加新' . $product_name, 'add_new_item' => '添加新' . $product_name, 'edit_item' => '编辑' . $product_name, 'new_item' => '新' . $product_name, 'view_item' => '查看' . $product_name, 'search_items' => '搜索' . $product_name, 'not_found' => '未找到' . $product_name, 'not_found_in_trash' => '回收站中未找到' . $product_name],
- 'public' => true,
- 'has_archive' => true,
- 'menu_icon' => 'dashicons-cart',
- 'show_in_rest' => true,
- 'supports' => ['title', 'editor', 'thumbnail', 'excerpt', 'comments', 'author'],
- 'rewrite' => ['slug' => $product_rewrite_slug]
- ]);
- register_taxonomy('product_category', 'product', [
- 'hierarchical' => true,
- 'labels' => ['name' => $product_name . '分类', 'singular_name' => $product_name . '分类', 'search_items' => '搜索' . $product_name . '分类', 'all_items' => '所有' . $product_name . '分类', 'parent_item' => '父级' . $product_name . '分类', 'parent_item_colon' => '父级' . $product_name . '分类:', 'edit_item' => '编辑' . $product_name . '分类', 'update_item' => '更新' . $product_name . '分类', 'add_new_item' => '添加新' . $product_name . '分类', 'new_item_name' => '新' . $product_name . '分类名称', 'menu_name' => $product_name . '分类'],
- 'show_ui' => true,
- 'show_admin_column' => true,
- 'query_var' => false,
- 'show_in_rest' => true,
- 'rewrite' => false,
- 'public' => false,
- 'publicly_queryable' => false
- ]);
- register_taxonomy('product_tag', 'product', [
- 'hierarchical' => false,
- 'labels' => ['name' => $product_name . '标签', 'singular_name' => $product_name . '标签', 'search_items' => '搜索' . $product_name . '标签', 'all_items' => '所有' . $product_name . '标签', 'edit_item' => '编辑' . $product_name . '标签', 'update_item' => '更新' . $product_name . '标签', 'add_new_item' => '添加新' . $product_name . '标签', 'new_item_name' => '新' . $product_name . '标签名称', 'menu_name' => $product_name . '标签'],
- 'show_ui' => true,
- 'show_admin_column' => true,
- 'query_var' => false,
- 'show_in_rest' => true,
- 'rewrite' => false,
- 'public' => false,
- 'publicly_queryable' => false
- ]);
- }
- function zyx_admin_product_posts_columns($columns)
- {
- $order = (isset($_REQUEST['order']) && ('desc' == $_REQUEST['order']) ? 'asc' : 'desc');
- if (isset($columns['cb'])) {
- $add_columns['cb'] = $columns['cb'];
- unset($columns['cb']);
- }
- if (isset($columns['title'])) {
- $add_columns['title'] = $columns['title'];
- unset($columns['title']);
- }
- if (isset($columns['author'])) {
- $add_columns['author'] = $columns['author'];
- unset($columns['author']);
- }
- $add_columns['all_count'] = '<a href="' . add_query_arg(['orderby' => 'views', 'order' => $order]) . '"><span>阅读</span></a>';
- $add_columns['assets'] = '<span>下载记录</span>';
- $add_columns['aut_price'] = '<span>购买价格</span>';
- $add_columns['aut_data'] = '<span>授权验证方式</span>';
- return array_merge($add_columns, $columns);
- }
- function zyx_admin_product_posts_custom_column($column_name, $posts_id)
- {
- $product_shop_options = get_post_meta($posts_id, 'product_shop_options', true);
- $product_parameter_options = get_post_meta($posts_id, 'product_parameter_options', true);
- switch ($column_name) {
- case 'aut_data':
- $type = '';
- switch (isset($product_shop_options['verify'])) {
- case 'domain':
- $type = '授权码+域名验证';
- break;
- case 'ip':
- $type = '授权码+IP验证';
- break;
- default:
- $type = '未知验证方式(配置缺失)';
- break;
- }
- echo '<div style="font-size: 12px;">' . $type . '</div>';
- break;
- case 'aut_price':
- $btns = $product_shop_options['zyx_btns'];
- $getapp = '';
- if ($btns) {
- foreach ($btns as $bv) {
- $getapp = zyx_aut_get_pay_name($btns, $product_shop_options['authpay']);
- }
- }
- echo $getapp;
- break;
- case 'all_count':
- $views = _cut_count((string) get_post_meta($posts_id, 'views', true));
- echo '<div style="font-size: 12px;">阅读 ' . $views . '</div>';
- break;
- case 'assets':
- $data = '<div style="font-size: 12px;">购买数量 ' . zyxpay_get_product($posts_id) . '</div>';
- $data .= zyxpay_get_paydown_log_admin_link('post', $posts_id, 'px12', $con = '[查看下载记录]');
- echo $data;
- break;
- }
- }
- function zyx_aut_get_pay_name($type, $authpay)
- {
- $user_id = get_current_user_id();
- $name = ['y' => '月卡授权', 'j' => '季卡授权', 'm' => '年卡授权', 'g' => '永久授权'];
- $uservip = zib_get_user_vip_level($user_id);
- $n = '';
- foreach ($type as $l => $bv) {
- if ($uservip == 2) {
- $pay = $authpay[$bv . '_2vip'];
- }
- else if ($uservip == 1) {
- $pay = $authpay[$bv . '_1vip'];
- }
- else {
- $pay = $authpay[$bv . '_pay'];
- }
- $_class = ($l == '0' ? ' active' : '');
- $n .= (isset($name[$bv]) ? $name[$bv] . ': ¥' . $pay . '<br>' : '还没有配置好');
- }
- return $n;
- }
- function zyx_post_thumbnail($size = '', $class = 'fit-cover', $show_url = false, $post = NULL)
- {
- if (!$size) {
- $size = zi_pz('thumb_postfirstimg_size');
- }
- if (!is_object($post)) {
- $post = get_post($post);
- }
- $cache_url = wp_cache_get($post->ID, 'post_thumbnail_url_' . $size, true);
- if (false === $cache_url) {
- $img_url = '';
- $post_thumbnail_id = get_post_thumbnail_id($post->ID);
- if ($post_thumbnail_id) {
- $image_src = zib_get_attachment_image_src($post_thumbnail_id, $size);
- $img_url = (isset($image_src[0]) ? $image_src[0] : '');
- }
- if (!$img_url) {
- $product_parameter_options = get_post_meta($post->ID, 'product_parameter_options', true);
- $img_url = $product_parameter_options['thumbnail_url'];
- }
- if (!$img_url && zi_pz('thumb_postfirstimg_s', true)) {
- $post_img_urls = zib_get_post_img_urls($post);
- $img_url = (isset($post_img_urls[0]) ? $post_img_urls[0] : '');
- if ($img_url && ($size && ('full' !== $size))) {
- $img_id = zib_get_image_id($img_url);
- if ($img_id) {
- $img = wp_get_attachment_image_src($img_id, $size);
- if (isset($img[0])) {
- $img_url = $img[0];
- }
- }
- }
- }
- wp_cache_set($post->ID, $img_url, 'post_thumbnail_url_' . $size);
- }
- else {
- $img_url = ('no' == $cache_url ? '' : $cache_url);
- }
- if ($show_url) {
- return $img_url;
- }
- $lazy_thumb = zib_get_lazy_thumb();
- $r_attr = '';
- $alt = $post->post_title . zib_get_delimiter_blog_name();
- if (!$img_url) {
- $img_url = zib_get_spare_thumb();
- $r_attr = ' data-thumb="default"';
- }
- if (zib_is_lazy('lazy_posts_thumb')) {
- return sprintf('<img' . $r_attr . ' src="%s" data-src="%s" alt="%s" class="lazyload ' . $class . '">', $lazy_thumb, $img_url, $alt);
- }
- else {
- return sprintf('<img' . $r_attr . ' src="%s" alt="%s" class="' . $class . '">', $img_url, $alt);
- }
- }
- function zyx_posts_related($related_title = '相关阅读', $limit = 6, $orderby = 'views')
- {
- global $post;
- $thumb_s = zyx_auth('post_related_type') == 'img';
- $categorys = get_the_terms($post, 'category');
- $topics = get_the_terms($post, 'topics');
- $tags = get_the_terms($post, 'post_tag');
- $posts_args = ['showposts' => $limit, 'ignore_sticky_posts' => 1, 'post_type' => 'product', 'post_status' => 'publish', 'order' => 'DESC', 'no_found_rows' => true];
- $posts_args = zib_query_orderby_filter($orderby, $posts_args);
- $posts_lits = '';
- $new_query = new WP_Query($posts_args);
- while ($new_query->have_posts()) {
- $new_query->the_post();
- if (zyx_auth('post_related_type') == 'list') {
- $posts_lits .= zib_posts_mini_while(['echo' => false, 'show_number' => false]);
- continue;
- }
- if ($thumb_s) {
- $title = get_the_title() . get_the_subtitle(false);
- $time_ago = zib_get_time_ago(get_the_time('Y-m-d H:i:s'));
- $info = '<item>' . $time_ago . '</item><item class="pull-right">' . zib_get_svg('view') . ' ' . get_post_view_count($before = '', $after = '') . '</item>';
- $img = zyx_post_thumbnail('', 'fit-cover', true);
- $img = ($img ? $img : zib_get_spare_thumb());
- $card = [
- 'type' => 'style-3',
- 'class' => 'mb10',
- 'img' => $img,
- 'alt' => $title,
- 'link' => ['url' => get_permalink(), 'target' => ''],
- 'text1' => $title,
- 'text2' => zib_str_cut($title, 0, 45, '...'),
- 'text3' => $info,
- 'lazy' => true,
- 'height_scale' => 70
- ];
- $posts_lits .= '<div class="swiper-slide mr10">';
- $posts_lits .= zib_graphic_card($card);
- $posts_lits .= '</div>';
- continue;
- }
- $posts_lits .= '<li><a class="icon-circle" href="' . get_permalink() . '">' . get_the_title() . get_the_subtitle() . '</a></li>';
- }
- wp_reset_query();
- wp_reset_postdata();
- $html = '<div class="theme-box relates' . ($thumb_s ? ' relates-thumb' : '') . '">' . "\n" . ' <div class="box-body notop">' . "\n" . ' <div class="title-theme">' . $related_title . '</div>' . "\n" . ' </div>';
- $html .= '<div class="zib-widget">';
- $html .= ($thumb_s ? '<div class="swiper-container swiper-scroll"><div class="swiper-wrapper">' : '<ul class="no-thumb">');
- if (!$posts_lits) {
- $html .= '<li>暂无相关文章</li>';
- }
- else {
- $html .= $posts_lits;
- }
- $html .= ($thumb_s ? '</div><div class="swiper-button-prev"></div><div class="swiper-button-next"></div></div>' : '</ul>');
- $html .= '</div></div>';
- return $html;
- }
- function get_user_ip()
- {
- if (getenv('HTTP_X_REAL_IP')) {
- $ip = getenv('HTTP_X_REAL_IP');
- }
- else if (getenv('HTTP_X_FORWARDED_FOR')) {
- $ips = explode(',', getenv('HTTP_X_FORWARDED_FOR'));
- $ip = trim($ips[0]);
- }
- else if (getenv('REMOTE_ADDR')) {
- $ip = getenv('REMOTE_ADDR');
- }
- else {
- $ip = 'UNKNOWN';
- }
- return $ip;
- }
- function zyx_get_qq_user_type()
- {
- $user = wp_get_current_user();
- $u = zyx_auth('qq-user');
- $flag = false;
- if (in_array('administrator', $user->roles) || in_array($user->ID, $u ? $u : [])) {
- $flag = true;
- }
- return $flag;
- }
- function zyx_ip_die($msg = '', $t = '')
- {
- if (!$t) {
- $t = (get_current_user_id() ? '绑定失败' : '登录失败');
- }
- $con = '<h4 class="c-red box-body separator mb30">' . $t . '</h4>';
- $con .= '<div class="mb20 muted-box text-left" style=" max-width: 600px; margin: auto; ">' . $msg . '</div>';
- $args = ['img' => ZIB_TEMPLATE_DIRECTORY_URI . '/img/null-user.svg', 'title' => $t . zib_get_delimiter_blog_name()];
- zyx_die_page($con, $args);
- }
- function zyx_die_page($message = '', $args = [])
- {
- $img = '<img src="' . ZIB_TEMPLATE_DIRECTORY_URI . '/img/404.svg">';
- if (isset($args['img'])) {
- $img = ($args['img'] ? '<img src="' . $args['img'] . '">' : '');
- }
- if (isset($args['title'])) {
- $GLOBALS['new_title'] = $args['title'];
- add_filter('echo_seo_title', '__return_true');
- }
- get_header();
- echo ' <main class="container flex ac">' . "\n" . ' <div class="f404 flex1">' . "\n" . ' ';
- echo $img . '<div class="f404-msg mt20">' . $message . '</div>';
- echo ' </div>' . "\n" . ' </main>' . "\n" . ' ';
- get_footer();
- exit();
- }
- function zyx_product_mistake_page()
- {
- $html = "\n" . ' <div class="plate-tab zib-widget">' . "\n" . ' <div class="text-center mb10" style="padding:60px 0;">' . "\n" . ' <img style="width:280px;opacity: .7;" src="/wp-content/themes/zibll/img/null-order.svg">' . "\n" . ' <p style="margin-top:10px;" class="em09 muted-3-color separator">暂无商品数据</p>' . "\n" . ' <div class="text-center em09 mt20">' . "\n" . ' <p>';
- if (!current_user_can('administrator')) {
- $html .= '<a href="javascript:;" class="signin-loader but jb-blue padding-lg">暂无商品,请联系管理员!</a>';
- }
- else {
- $html .= '<a target="_blank" href="' . add_query_arg('post_type', 'product', admin_url('post-new.php')) . '" class="signup-loader but jb-yellow padding-lg">立即添加商品</a>';
- }
- $html .= '</p>' . "\n" . ' </div></div>' . "\n" . ' </div>';
- return zib_get_ajax_ajaxpager_one_centent($html);
- }
- function zyx_product_advance_page($post_id)
- {
- $zyx_advance = zyx_advance($post_id);
- $product_shop_options = get_post_meta($post_id, 'product_shop_options', true);
- $html = "\n" . ' <div class="plate-tab zib-widget">' . "\n" . ' <div class="text-center mb10" style="padding:60px 0;">' . "\n" . ' <img style="width:280px;opacity: .7;" src="/wp-content/themes/zibll/img/null-set.svg">' . "\n" . ' <p style="margin-top:10px;" class="em09 muted-3-color separator">产品将于 <spen class="c-red">' . $zyx_advance['end_time'] . '</spen> 发布 请耐心等待!</p>' . "\n" . ' <div class="text-center em09 mt20">' . "\n" . ' <p>';
- if ($product_shop_options['download_qun_url']['url']) {
- $html .= '<a class="signin-loader but jb-blue padding-lg" target="' . $product_shop_options['download_qun_url']['target'] . '" href="' . $product_shop_options['download_qun_url']['url'] . '">加入正版群</a>';
- }
- $html .= '</p>' . "\n" . ' </div></div>' . "\n" . ' </div>';
- return zib_get_ajax_ajaxpager_one_centent($html);
- }
- function zyx_product_aut_manage_page()
- {
- $html = "\n" . ' <div class="plate-tab zib-widget">' . "\n" . ' <div class="text-center mb10" style="padding:60px 0;">' . "\n" . ' <img style="width:280px;opacity: .7;" src="/wp-content/themes/zibll/img/null-set.svg">' . "\n" . ' <p style="margin-top:10px;" class="em09 muted-3-color separator">暂无权限</p>' . "\n" . ' <div class="text-center em09 mt20">' . "\n" . ' <p>';
- $html .= '<a href="javascript:;" class="signin-loader but jb-blue padding-lg">无权访问此页面 请先成为开发者并发布产品</a>';
- $html .= '</p>' . "\n" . ' </div></div>' . "\n" . ' </div>';
- return zib_get_ajax_ajaxpager_one_centent($html);
- }
- function zyx_product_activity($post_id)
- {
- $checkLimitedTimeOffer = checkLimitedTimeOffer($post_id);
- if (!$checkLimitedTimeOffer) {
- return NULL;
- }
- if (empty($checkLimitedTimeOffer['end_time']) || (empty($checkLimitedTimeOffer['title']) && empty($checkLimitedTimeOffer['description']))) {
- return NULL;
- }
- $new_time = current_time('Y-m-d H:i:s');
- $end_time = date('m/d/Y H:i:s', strtotime($checkLimitedTimeOffer['end_time']));
- $html = '<div class="countdown-activity flex jc">';
- $html .= '<div class="activity-content flex ac">';
- $html .= (!empty($checkLimitedTimeOffer['title']) ? '<div class="activity-title mr10">' . $checkLimitedTimeOffer['title'] . '</div>' : '');
- $html .= (!empty($checkLimitedTimeOffer['description']) ? '<div class="activity-desc">' . $checkLimitedTimeOffer['description'] . '</div>' : '');
- $html .= '</div>';
- $html .= '<div class="countdown-content badg jb-yellow radius flex jc">';
- $html .= '<div class="countdown-desc">活动倒计时</div>';
- $html .= '<div class="countdown-time flex0 em09-sm badg jb-vip2 radius" data-over-text="活动已结束" data-newtime="' . $new_time . '" data-countdown="' . $end_time . '">';
- $html .= 'X天X小时X分X秒';
- $html .= '</div>';
- $html .= '</div>';
- $html .= '</div>';
- return $html;
- }
- function zyx_product_advance($post_id)
- {
- $zyx_advance = zyx_advance($post_id);
- if (!$zyx_advance) {
- return NULL;
- }
- if (empty($zyx_advance['end_time']) || (empty($zyx_advance['title']) && empty($zyx_advance['description']))) {
- return NULL;
- }
- $new_time = current_time('Y-m-d H:i:s');
- $end_time = date('m/d/Y H:i:s', strtotime($zyx_advance['end_time']));
- $html = '<div class="countdown-activity flex jc">';
- $html .= '<div class="activity-content flex ac">';
- $html .= (!empty($zyx_advance['title']) ? '<div class="activity-title mr10">' . $zyx_advance['title'] . '</div>' : '');
- $html .= (!empty($zyx_advance['description']) ? '<div class="activity-desc">' . $zyx_advance['description'] . '</div>' : '');
- $html .= '</div>';
- $html .= '<div class="countdown-content badg jb-yellow radius flex jc">';
- $html .= '<div class="countdown-desc">预售倒计时</div>';
- $html .= '<div class="countdown-time flex0 em09-sm badg jb-vip2 radius" data-over-text="预售已结束" data-newtime="' . $new_time . '" data-countdown="' . $end_time . '">';
- $html .= 'X天X小时X分X秒';
- $html .= '</div>';
- $html .= '</div>';
- $html .= '</div>';
- return $html;
- }
- function zyxpay_updata_pay_down_mate($post_id, $down_id, $paid)
- {
- $user_id = get_current_user_id();
- $order_date = zyx_product_order_date($user_id, $post_id);
- $user_log_data = ['order_num' => !empty($order_date[0]['pay_num']) ? $order_date[0]['pay_num'] : '', 'post_id' => $post_id, 'down_id' => $down_id];
- zyxpay_updata_user_down_log($user_id, $user_log_data);
- $poat_log_data = ['order_num' => !empty($order_date[0]['pay_num']) ? $order_date[0]['pay_num'] : '', 'user_id' => $user_id, 'down_id' => $down_id];
- zyxpay_updata_post_down_log($post_id, $poat_log_data);
- }
- function zyx_get_remote_ip_addr()
- {
- if (getenv('HTTP_X_REAL_IP')) {
- $ip = getenv('HTTP_X_REAL_IP');
- }
- else if (getenv('HTTP_X_FORWARDED_FOR')) {
- $ips = explode(',', getenv('HTTP_X_FORWARDED_FOR'));
- $ip = trim($ips[0]);
- }
- else if (getenv('REMOTE_ADDR')) {
- $ip = getenv('REMOTE_ADDR');
- }
- else {
- $ip = '';
- }
- return $ip;
- }
- function zyxpay_updata_user_down_log($user_id, $data)
- {
- $max = (int) _pz('pay_type_option', 0, 'down_user_log');
- if (!$max) {
- return false;
- }
- $defaults = ['paid_type' => '', 'order_num' => '', 'post_id' => '', 'down_id' => '', 'time' => current_time('Y-m-d H:i'), 'ip' => zyx_get_remote_ip_addr()];
- $data = wp_parse_args($data, $defaults);
- if (!$data['post_id']) {
- return false;
- }
- $meta_key = 'pay_product_down_log';
- $record = zib_get_user_meta($user_id, $meta_key, true);
- if (!$record || !is_array($record)) {
- $record = [];
- }
- $record = array_slice($record, 0, $max - 1, true);
- $new_record = array_merge([$data], $record);
- return zib_update_user_meta($user_id, $meta_key, $new_record);
- }
- function zyxpay_updata_post_down_log($post_id, $data)
- {
- $max = (int) _pz('pay_type_option', 0, 'down_post_log');
- if (!$max) {
- return false;
- }
- $defaults = ['paid_type' => '', 'order_num' => '', 'user_id' => '', 'down_id' => '', 'time' => current_time('Y-m-d H:i'), 'ip' => zyx_get_remote_ip_addr()];
- $data = wp_parse_args($data, $defaults);
- $meta_key = 'pay_product_down_log';
- $record = zib_get_post_meta($post_id, $meta_key, true);
- if (!$record || !is_array($record)) {
- $record = [];
- }
- $record = array_slice($record, 0, $max - 1, true);
- $new_record = array_merge([$data], $record);
- return zib_update_post_meta($post_id, $meta_key, $new_record);
- }
- if (!defined('ABSPATH')) {
- exit();
- }
- $include_once = ['zyx-update', 'zyx-log', 'zyx-sql', 'zyx-msg', 'zyx-ajax', 'zyx-tool', 'zyx-modal', 'zyx-class', 'zyx-link', 'zyx-posts', 'zyx-search', 'zyx-statistics', 'zyx-rewrites', 'auth/zyx-page', 'auth/zyx-auth', 'auth/zyx-admin', 'acting/zyx-tab', 'acting/zyx-pay', 'acting/zyx-ajax', 'card/zyx-cardamom', 'card/cardamom-ajax', 'card/zyx-promo', 'api/zyx-detection', 'api/zyx-anncmnt', 'api/zyx-aut', 'api/zyx-update', 'api/zyx-api', 'api/zyx-promo', 'user/side', 'user/report', 'user/query', 'user/page', 'help/zyx-help', 'widgets/functions'];
- foreach ($include_once as $inc) {
- include $inc . '.php';
- }
- zyxauth::init();
- add_action('wp_enqueue_scripts', 'zyx_add_wp_enqueue');
- add_filter('wp_sitemaps_add_provider', function($provider, $name) {
- return $name == 'taxonomies' ? false : $provider;
- }, 10, 2);
- if (!function_exists('is_current_page_aut')) {
- function is_current_page_aut()
- {
- $current_path = $_SERVER['REQUEST_URI'];
- $current_path = rtrim($current_path, '/');
- if ($current_path === '/aut') {
- return true;
- }
- return false;
- }
- }
- add_action('init', 'zyx_custom_product_setup');
- add_filter('manage_product_posts_columns', 'zyx_admin_product_posts_columns');
- add_action('manage_product_posts_custom_column', 'zyx_admin_product_posts_custom_column', 11, 2);
- add_action('zyxpay_download_before', 'zyxpay_updata_pay_down_mate', 10, 3);
- ?>
Advertisement
Add Comment
Please, Sign In to add comment