<?php

if (function_exists('rcl_enqueue_style')) {
    rcl_enqueue_style('private', __FILE__);
}
function rcl_count_noread_messages($user_id)
{
    global $wpdb;
    $where = "WHERE adressat_mess = '{$user_id}' AND status_mess='0'";
    return $wpdb->get_var("SELECT COUNT(ID) FROM " . RCL_PREF . "private_message {$where}");
}
add_action('wp', 'rcl_download_file_message');
function rcl_download_file_message()
{
    global $user_ID, $wpdb;
    if (!isset($_GET['rcl-download-id'])) {
        return false;
    }
    $id_file = base64_decode($_GET['rcl-download-id']);
    if (!$user_ID || !wp_verify_nonce($_GET['_wpnonce'], 'user-' . $user_ID)) {
        return false;
    }
    $file = $wpdb->get_row($wpdb->prepare("SELECT * FROM " . $wpdb->prefix . "rcl_private_message WHERE ID = '%d' AND adressat_mess = '%d' AND status_mess = '5'", $id_file, $user_ID));
    if (!$file) {
        wp_die(__('File does not exist on the server or it has already been loaded!', 'wp-recall'));
    }
    $name = explode('/', $file->content_mess);
    $cnt = count($name);
    $f_name = $name[--$cnt];
    $wpdb->update(RCL_PREF . 'private_message', array('status_mess' => 6, 'content_mess' => __('The file was loaded.', 'wp-recall')), array('ID' => $file->ID));
    header('Content-Description: File Transfer');
<?php

if (function_exists('rcl_enqueue_style')) {
    rcl_enqueue_style('feed', __FILE__);
}
require_once 'addon-core.php';
require_once 'shortcodes.php';
add_action('init', 'rcl_add_block_feed_button');
function rcl_add_block_feed_button()
{
    rcl_block('header', 'rcl_add_feed_button', array('id' => 'fd-footer', 'order' => 5, 'public' => -1));
}
function rcl_add_feed_button($user_id)
{
    global $user_ID;
    if (!$user_ID || $user_ID == $user_id) {
        return false;
    }
    if (rcl_get_feed_author_current_user($user_id)) {
        return rcl_get_feed_callback_link($user_id, __('Unsubscribe', 'wp-recall'), 'rcl_update_feed_current_user');
    } else {
        return rcl_get_feed_callback_link($user_id, __('Subscribe', 'wp-recall'), 'rcl_update_feed_current_user');
    }
}
function rcl_add_userlist_follow_button()
{
    global $rcl_user;
    echo '<div class="follow-button">' . rcl_add_feed_button($rcl_user->ID) . '</div>';
}
add_filter('ajax_tabs_rcl', 'rcl_ajax_followers_tab');
function rcl_ajax_followers_tab($array_tabs)
<?php

require_once 'groups-init.php';
require_once 'groups-core.php';
require_once 'shortcodes.php';
if (is_admin()) {
    require_once 'groups-options.php';
}
require_once 'groups-widgets.php';
if (!is_admin()) {
    require_once 'groups-public.php';
}
require_once 'upload-avatar.php';
rcl_enqueue_style('groups', __FILE__);
if (function_exists('rcl_register_rating_type')) {
    if (!is_admin()) {
        add_action('init', 'rcl_register_rating_group_type');
    }
    if (is_admin()) {
        add_action('admin_init', 'rcl_register_rating_group_type');
    }
    function rcl_register_rating_group_type()
    {
        rcl_register_rating_type(array('post_type' => 'post-group', 'type_name' => __('Record groups', 'wp-recall'), 'style' => true));
    }
}
add_filter('taxonomy_public_form_rcl', 'rcl_add_taxonomy_public_groups');
function rcl_add_taxonomy_public_groups($tax)
{
    if (!isset($tax['post-group'])) {
        $tax['post-group'] = 'groups';
<?php

if (function_exists('rcl_register_rating_type')) {
    require_once 'rating-review.php';
}
rcl_enqueue_style('review', __FILE__);
add_filter('ajax_tabs_rcl', 'rcl_ajax_tab_review');
function rcl_ajax_tab_review($array_tabs)
{
    $array_tabs['recall'] = array('Rcl_Review', 'get_content_review');
    return $array_tabs;
}
add_action('init', 'rcl_tab_review');
function rcl_tab_review()
{
    rcl_tab('recall', array('Rcl_Review', 'get_content_review'), __('Reviews', 'wp-recall'), array('public' => 1, 'class' => 'fa-trophy', 'order' => 50, 'path' => __FILE__));
}
class Rcl_Review
{
    public function __construct()
    {
        if (!is_admin()) {
            add_action('init', array(&$this, 'add_review_activate'));
            add_action('init', array(&$this, 'delete_review_activate'));
        } else {
            add_filter('admin_options_wprecall', array(&$this, 'get_review_options'));
        }
        add_action('delete_user', array(&$this, 'delete_reviews_user'));
    }
    //Оставляем пользователю отзыв
    function add_review()
<?php

rcl_enqueue_style('rmag', __FILE__);
function rmag_global_unit()
{
    if (defined('RMAG_PREF')) {
        return false;
    }
    global $wpdb, $rmag_options, $user_ID;
    if (!isset($_SESSION['return_' . $user_ID])) {
        $_SESSION['return_' . $user_ID] = $_SERVER['HTTP_REFERER'];
    }
    $rmag_options = get_option('primary-rmag-options');
    define('RMAG_PREF', $wpdb->prefix . "rmag_");
}
add_action('init', 'rmag_global_unit', 10);
if (!session_id()) {
    session_start();
}
require_once "functions.php";
require_once "admin-pages.php";
require_once "functions/shortcodes.php";
require_once "functions/ajax-func.php";
function rcl_ajax_tab_order($array_tabs)
{
    $array_tabs['order'] = 'rcl_orders';
    return $array_tabs;
}
add_filter('ajax_tabs_rcl', 'rcl_ajax_tab_order');
add_action('init', 'rcl_tab_orders');
function rcl_tab_orders()
<?php

include_once 'classes.php';
include_once 'fast-editor.php';
include_once 'upload-file.php';
include_once 'addon-options.php';
rcl_enqueue_style('publics', __FILE__);
//if (!session_id()) { session_start(); }
if (!is_admin()) {
    add_action('wp_enqueue_scripts', 'rcl_publics_scripts');
}
function rcl_publics_scripts()
{
    global $rcl_options;
    //if($rcl_options['media_downloader_recall']!=1) return false;
    wp_enqueue_script('jquery');
    wp_enqueue_script('rcl_publics_scripts', rcl_addon_url('js/scripts.js', __FILE__));
}
function rcl_autocomplete_scripts()
{
    wp_enqueue_style('rcl_autocomplete_scripts', rcl_addon_url('js/magicsuggest/magicsuggest-min.css', __FILE__));
    wp_enqueue_script('jquery');
    wp_enqueue_script('rcl_autocomplete_scripts', rcl_addon_url('js/magicsuggest/magicsuggest-min.js', __FILE__));
}
if (!is_admin()) {
    add_filter('the_content', 'rcl_post_gallery', 10);
}
if (!is_admin() || defined('DOING_AJAX')) {
    add_filter('the_content', 'rcl_author_info', 100);
}
add_action('admin_menu', 'rcl_admin_page_publicform', 30);
<?php

require_once 'core.php';
require_once 'addon-options.php';
require_once 'class_rayting.php';
if (function_exists('rcl_enqueue_style')) {
    rcl_enqueue_style('rating-system', __FILE__);
}
if (is_admin()) {
    add_action('admin_head', 'rcl_add_admin_rating_scripts');
}
function rcl_add_admin_rating_scripts()
{
    wp_enqueue_script('jquery');
    wp_enqueue_script('rcl_admin_rating_scripts', plugins_url('js/admin.js', __FILE__));
}
if (!is_admin()) {
    add_action('init', 'rcl_register_rating_base_type', 30);
}
if (is_admin()) {
    add_action('admin_init', 'rcl_register_rating_base_type', 30);
}
function rcl_register_rating_base_type()
{
    rcl_register_rating_type(array('post_type' => 'post', 'type_name' => __('Posts', 'wp-recall'), 'style' => true, 'data_type' => true, 'limit_votes' => true, 'icon' => 'fa-thumbs-o-up'));
    rcl_register_rating_type(array('rating_type' => 'comment', 'type_name' => __('Comments', 'wp-recall'), 'style' => true, 'data_type' => true, 'limit_votes' => true, 'icon' => 'fa-thumbs-o-up'));
}
add_filter('rcl_post_options', 'rcl_get_post_rating_options', 10, 2);
function rcl_get_post_rating_options($options, $post)
{
    $mark_v = get_post_meta($post->ID, 'rayting-none', 1);
<?php

rcl_enqueue_style('user_account', __FILE__);
include_once "rcl_payment.php";
include_once 'gateways/robokassa.php';
include_once 'gateways/interkassa.php';
include_once 'gateways/walletone.php';
//include_once 'gateways/yandexkassa.php';
function rcl_payform($args)
{
    $payment = new Rcl_Payment();
    return $payment->get_form($args);
}
function rmag_get_global_unit_wallet()
{
    if (!defined('RMAG_PREF')) {
        global $wpdb;
        global $rmag_options;
        $rmag_options = get_option('primary-rmag-options');
        define('RMAG_PREF', $wpdb->prefix . "rmag_");
    }
}
add_action('init', 'rmag_get_global_unit_wallet', 10);
if (is_admin()) {
    add_action('admin_head', 'rcl_admin_user_account_scripts');
}
function rcl_admin_user_account_scripts()
{
    wp_enqueue_script('jquery');
    wp_enqueue_script('rcl_admin_user_account_scripts', plugins_url('js/admin.js', __FILE__));
}