Plugin Directory

Changeset 2313295


Ignore:
Timestamp:
05/27/2020 05:23:01 PM (6 years ago)
Author:
Shmidtelson
Message:

1.0.4.2 ver

Location:
wp-post-rating/trunk
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • wp-post-rating/trunk/classes/admin/RatingsList.php

    r2269438 r2313295  
    171171        $paged = isset($_REQUEST['paged']) ? max(0, intval($_REQUEST['paged']) - 1) : 0;
    172172        $orderby = (isset($_REQUEST['orderby']) && in_array($_REQUEST['orderby'], array_keys($this->get_sortable_columns()))) ? $_REQUEST['orderby'] : 'id';
    173         $order = (isset($_REQUEST['order']) && in_array($_REQUEST['order'], ['asc', 'desc'])) ? $_REQUEST['order'] : 'asc';
     173        $order = (isset($_REQUEST['order']) && in_array($_REQUEST['order'], ['asc', 'desc'])) ? $_REQUEST['order'] : 'desc';
    174174        $offset = $per_page * $paged;
    175175        // [REQUIRED] define $items array
  • wp-post-rating/trunk/readme.txt

    r2269443 r2313295  
    44Tags: 5 star, google rating, postrating, rating, ratings, seo rating, rating snippet
    55Requires at least: 4.9.8
    6 Tested up to: 5.4
     6Tested up to: 5.4.1
    77Requires PHP: 5.6
    8 Stable tag: 1.0.4.1
     8Stable tag: 1.0.4.2
    99License: GPLv2 or later
    1010License URI: http://www.gnu.org/licenses/gpl-2.0.html
     
    3838
    3939== Changelog ==
     40= 1.0.4.2 =
     41* Fix vote table default sort in admin area
     42* Small refactoring
    4043= 1.0.4.1 =
    4144* Fix bug with pagination all votes in admin area
  • wp-post-rating/trunk/wp-post-rating.php

    r2269443 r2313295  
    55Plugin URI: http://romua1d.ru/wp_post_rating
    66Description: Powerful post rating wordpress plugin.
    7 Version: 1.0.4.1
     7Version: 1.0.4.2
    88Author: Romua1d
    99Author URI: https://romua1d.ru
     
    2121
    2222if (!class_exists('InitRating')) {
    23 
    2423    class InitRating
    2524    {
    26         public $position;
     25        public $position = 'shortcode';
    2726        public $wprStarsMainColor;
    2827        public $wprStarsSecondColor;
    2928
    30         public $lang_vote = '';
    31 
    3229        public function __construct()
    3330        {
    34             // display rating
    35 
    36 //            add_filter('the_content', [$this, 'add_rating_after_content']);
    3731            add_action('wp_enqueue_scripts', [$this, 'include_css_js']);
    3832
     
    4034            add_action('wp_head', [$this, 'add_meta_nonce']);
    4135
    42             // Interalization
     36            // Internationalization
    4337            add_action('init', [$this, 'load_plugin_text_domain']);
    4438
     
    6559
    6660            // Add settings link
    67 //            add_filter("plugin_action_links_{$this->config->PLUGIN_NAME}", [$this, 'add_settings_link_to_plugin_list']);
    68 
    6961            add_filter("plugin_action_links_" . plugin_basename(__FILE__), [$this, 'add_settings_link_to_plugin_list']);
    7062
     
    10698        }
    10799
    108 //        public function add_rating_after_content($content)
    109 //        {
    110 //
    111 //            if (is_single() && $this->position == 'before')
    112 //                require_once $this->config->PLUGIN_PATH . 'templates' . DIRECTORY_SEPARATOR . 'main.php';
    113 //
    114 //            echo do_shortcode($content);
    115 //            print $content;
    116 //
    117 //            if (is_single() && $this->position == 'after')
    118 //                require_once $this->config->PLUGIN_PATH . 'templates' . DIRECTORY_SEPARATOR . 'main.php';
    119 //        }
    120 
     100        /**
     101         * @return bool
     102         */
    121103        public function load_plugin_text_domain()
    122104        {
     
    125107                trailingslashit(WP_LANG_DIR) . $this->config->PLUGIN_NAME . DIRECTORY_SEPARATOR . $this->config->PLUGIN_NAME . '-' . $locale . '.mo')) {
    126108                return $loaded;
    127             } else {
    128                 load_plugin_textdomain($this->config->PLUGIN_NAME, false, basename(dirname(__FILE__)) . '/languages/');
    129109            }
     110
     111            return load_plugin_textdomain($this->config->PLUGIN_NAME, false, basename(dirname(__FILE__)) . '/languages/');
    130112        }
    131113
     
    144126        }
    145127
    146         /**
    147          * @return string
    148          */
    149128        public function add_meta_nonce()
    150129        {
     
    180159
    181160    $WPR_PLUGIN = new InitRating;
    182 
    183161}
    184162
Note: See TracChangeset for help on using the changeset viewer.