=== Multi Rating Pro === Contributors: dpowney Tags: rating, review, post rating, star rating, seo, schema.org, json-ld Requires at least: 4.0 Tested up to: 5.7 Stable tag: trunk License: GPLv2 or later License URI: http://www.gnu.org/licenses/gpl-2.0.html A powerful rating system and review plugin for WordPress. == Changelog == = 6.0.7 = * Fix: Tweak to JSON encoding for JSON-LD structured data * Bug: Fixed stray . in SQL causing error in SQL v8 = 6.0.6 = * New: Added mrp_structured_data_item_type filter * Fix: Special characters causing invalid JSON-LD markup * New: Added mrp_filter_taxonomy_post_types filter to support other post types (only post and page post types are enabled by default) = 6.0.5 = * Fix: Review JSON-LD syntax error = 6.0.4 = * Fix: Stray ASCII character causing syntax error in some environments * Fix: User ratings dashboard average rating was hard coded out of 5 = 6.0.3 = * Fix: Thumbs down counts not included in rating item results = 6.0.2 = * Fix: Gutenberg Block editor error due to API response to get rating forms not available immediately * Fix: Console error in Gutenberg editor due to icon_classes missing * Fix: Deprecated jQuery function live() was used in admin JS = 6.0.1 = * Fix: PHP error for custom image styles = 6.0 = * Important: Several style and template changes. If you are using custom templates or have custom CSS please test! * Bug: Fixed allow anonymous ratings option not displaying correctly in the post meta box * New: Included REST API support in core plugin. Tweaked rating-forms JSON response with an id to work with Gutenberg. * Tweak: Upgraded Font Awesome icons to latest v3 & v4 and added v5 * Tweak: Removed custom CSS option. You should move this to the Customizer. * Tweak: Removed widget check for enabled post types. * Tweak: Removed minified assets and option in style settings. * Tweak: Removed default microdata item type settings. You now need to set this on each post. * Tweak: Fixed typo in general settings for keep trailing zeroes * Tweak: Changed classic editor post meta box styles. * Tweak: Removed custom CSS option. You should move this to the Customizer. * New: Added JSON-LD AggregateRating and Review structured data on posts. Removed old microdata format which was previously used. * New: Added integration with WooCommerce Product structured data * New: Added integration with Wordpress SEO (Yoast) structured data graph * New: Added 5 Gutenberg blocks for the rating form, rating result, rating result list, rating entry details list and rating item results. * New: Migrated post meta settings to Gutenberg editor. * Bug: Fixed a load more button conflict for rating entry details * New: Added quick delete in rating entries WP-admin page * Tweak: Removed post type check from the mr_can_apply_filter filter. This allows auto placement even when the post type is not enabled using post meta fields. = 5.5.1 (23/10/2019) = * Tweak: Added general setting and post meta options to specify microdata itemtype for SERP ratings and reviews * Bug: Added fix to support updating ratings in different languages for WPML * Bug: Added fix for PHP warning in misc-functions.php line 756 * Bug: Fixed mrp_rating_item_results filters not working * Bug: Fixed shortcode filters using translated terms in WPML = 5.5 (14/04/2018) = * Bug: Invalid parameter used when counting bulk actions on rating entries page * Tweak: Removed IP address duplicate checking for GDPR compliance. Cookies will be the default option used instead. * Bug: Polylang compatability issue with the wrong db table prefix used in a query * Tweak: Scalability fix recacluating ratings = 5.4.5 (08/04/2018) = * Bug: Fixed Polylang compatibility for disabled post types * Bug: Polylang & WPML compatibility fix to recalculate translated post ratings on update * Bug: Do not show the migration tool if rating items from free version are not available = 5.4.4 (01/04/2018) = * Bug: Fixed Polylang issue not showing rating entries for all languages in WP-admin * Tweak: Added new option to keep any trailing zeros in star rating and score result types e.g. 3.0/5.0 * Bug: Fixed comment moderation not working when rating items are added to the comment form * Bug: Fixed sql_mode=only_full_group_by incompatibility issue * Bug: Fixed post_ids bug in mrp_rating_results_list() and mrp_rating_item_results() template tags * Bug: Fixed a space issue between two HTML element attributes in rating-form-thumbs.php template = 5.4.3 (11/12/2017) = * Bug: Allow private post calculated ratings to be shown in WP-admin = 5.4.2 (28/11/2017) = * Bug: Fixed e-mail publicly shown instead of name in the [mrp_rating_entry_details_list] shortcode = 5.4.1 (27/11/2017) = * Bug: Fix to allow override whether to show a review field using shortcode attributes, but only if the review field has been added to the rating form = 5.4 (17/11/2017) = * Bug: Enabled displaying avatars for anonymous users by updating the get_avatar() call in the rating-entry-details.php template file to use email instead of the user id. * Tweak: Increased maximum comment length to 2000 characters * Bug: Rating entries are now stored against the current language post id in WPML * New: Polylang plugin compatibility added in line with WPML implementation * Tweak: Changed API function user_rating_exists() inputs to an array of parameters. Added backwards compatibility for old API function parameters * Bug: Fixed percentage rounding error in rating item results template options block layout * Bug: Fixed term_id filter not working when retrieving rating entries * Bug: Fixed slash in custom field output * Bug: Upon plugin activation, do not redirect to about page if network admin * Tweak: Added extra isset checks in rating-result.php template file * Bug: Fixed default rating item results widget title * Bug: Fixed WPML admin-texts not working * Tweak: Replaced the mrp_disable_custom_text filter with a new option in the Advanced settings tab * Bug: Fixed incorrect CSS class of rating results shown after a rating is saved or deleted * Bug: Fixed WPML string translations for rating form, rating items and custom fields = 5.3.1 (27/06/2017) = * Bug: Fixed email headers not set correctly = 5.3.0 (07/06/2017) = * Bug: Update post meta fields with ratings data when ratings are found missing and are calculated * Bug: Fixed limit & offset wrong way around in db queries * Tweak: Moved static sequence variable from rating form class to utility class * New: Added AJAX load more for rating entry details shortcode & widget * Tweak: Added id to header when editig rating entry, rating form, rating item and custom fields * Tweak: Disabled reports menu until new enhanced reports are made available * Tweak: Added capabilities that are needed to access various plugins tools (e.g. export) * Tweak: Modified rating-entry-details-list template file for AJAX load more and added a new rating-entry-details template file * New: Added add author link option to Rating Entry List widget * Tweak: Set default Limit option from 10 to 3 in Rating Entry List widget * Tweak: Remove unused utility functions validate_rating_items_id_list() and validate_custom_fields_id_list() * New: Added new mrp_manage_ratings, mrp_export_ratings and mrp_delete_ratings role capabilities. Added tighter security checks for role capabilities. * Tweak: Moved edit rating screen to rating entries page slug * New: Allow users to manually add ratings from WP-admin (only available to users with mrp_manage_ratings capability) * Tweak: Updated language translation file * Tweak: Added wp_trim_words() to comment text in rating entries WP-admin table * Bug: Fixed unable to moderate ratings with long comments from the WordPress comment system = 5.2.8 (24/04/2017) = * Bug: Removed stray die() in code after a rating entry has been manually approved on unapproved by a moderator * Bug: Fixed typo in filters page for auto placement of rating result * New: Added RSS feed for rating entries named mrp_rating_entries * Bug: Fixed IP address duplicate checks not working = 5.2.7 (06/04/2017) = * Bug: Added @ to set_time_limit function call to suppress errors/warnings * Bug: Added star rating items to be able to only show text options (in case you do not want to show 0 star option totals in the [mrp_rating_item_results] shortcode) = 5.2.6 (03/04/2017) = * Bug: Fixed missing mrp_after_rating_form_validation_save filter which is used by the reCAPTCHA add-on * Tweak: Fined tuned filters used for hash lookups * New: Added the ability to reassign a rating entry to a different user in WP-admin * New: Added the ability to edit the rating entry date in WP-admin * Bug: Fixed translations not loading * Tweak: Updated validation to use current_user_can( 'mrp_moderate_ratings' ) when updating or deleting rating entries = 5.2.5 (25/02/2017) = * New: Font Awesome 4.7.0 support * Bug: Fixed some potential SQL injection vulnerabilities * Bug: Fixed a couple of cross site scripting (XSS) vulnerabilities in the rating form * Bug: Small HTML5 validation improvement in rating forms page for weights * Bug: WPML query fix * Bug: Fixed title not showing for rating entries list widget * Bug: Added add_author_link shortcode attribute to the [mrp_rating_entry_details_list] shortcode * New: Removed hover color on stars when mouse out and no stars selected * New: Added ability to sort by oldest rating entries * Bug: Replaced GROUP_CONTACT usage from cleanup database queries as this truncates results when column length > 1024 characters * New: Added mrp_disable_custom_text filter to turn off custom text settings allowing language translation of strings * Bug: Fixed title review field not saving with WordPress comment form * Bug: Fixed incorrect custom fields values showing in CSV file when not required * Tweak: Updated language files * Bug: Added HTML5 required validation to review fields in WP-admin edit rating page * Tweak: Removed count comments from the calculated ratings db table and relevent objects * Tweak: Reordered the migration tool to the bottom of the tools page * Tweak: Changed CSV export files to now be temporarily saved in the plugin root directory to avoid potential permission issues = 5.2.4 (12/12/2016) = * Bug: Fixed call to undefined function apply_filter() in template-tags.php; changed to apply_filters() = 5.2.3 (8/12/2016) = * Bug: Added missing validation of post id and rating form id when saving a rating entry = 5.2.2 (19/11/2016) = * Bug: Fixed WPML incorrect query resulting in no ratings being retrieved * New: Added mrp_before_save_rating_entry hook * Bug: Fixed rating moderation not working if setting to allow users to update or delete ratings is turned on * Bug: Fixed WPML compatibility for custom post types = 5.2.1 (18/11/2016) = * New: Added rank to rating item results * New: Added sort_by to rating item results for the options_inline and no_options layouts * Bug: Fixed WPML compatibility erro due to ambiguous post_id column when retrieving rating entries * Bug: Fixed IP address not saved correctly with a new rating entry * Bug: Fixed rating entries being incorrectly deleted on recalculate ratings and clean the database tools whenever a rating entry has an invalid rating item value (i.e. no longer associated to a rating item) = 5.2 (14/11/2016) = * Bug: Fixed review field required error not disappearing after submit * Bug: Allow weight of 0 for rating items in a rating form * Bug: Allow post meta to use default settings for rating form * Bug: Fix for WPML to not show ratings for posts if they have not been translated to the current language yet * Tweak: Cleaned up the tools page under the covers * Bug: Fixed deleting rating item from rating items page causing any rating forms which had this rating item to be in error * Tweak: Turned off auto placement in RSS feeds by checking the is_feed() function. Note a simple way to flush an RSS feed cache is to update a post. * Bug: Added missing published post status check in the rating results list where clause * New: Added the ability to dynamically set the user id on a page for the [mrp_user_rating_results] shortcode via URL query string parameter * New: Deprecated the following API functions replaced by template tags in template-tags.php: display_rating_form(), display_rating_result() display_rating_entry_details_list(), display_rating_results_list(), display_user_rating_results(), get_comment_rating_result(), get_comment_rating_form(), display_user_ratings_dashboard(), display_rating_item_results() and delete_rating_result() * New: Refactored code to use new API functions delete_calculated_ratings() delete_orphaned_data(), reassign_user_ratings(), save_rating_form(), delete_rating_form(), save_rating_entry() and delete_rating_entry() * Tweak: Removed a couple of self:: with MRP_Multi_Rating:: * Bug: Added dashicons thumbs up and thumbs down support * Tweak: Display star ratings in admin as dashicons * Tweak: Added localized strings used in JavaScript * Tweak: Moved JavaScript functions outside of jQuery ready so that they are available earlier * Tweak: Removed mrp_rating_results_html filter and replaced with a mrp_rating_result_callback filter so you can replace the function which create the HTML for auto placement of the rating results * New: Added mrp_rating_form_callback filter so you can replace the function which creates them HTML for auto placement of the rating form * Tweak: Changed default decimal places from 2 to 1 * Tweak: Updated parameters passed to mrp_auto_approve_ratings filter, mrp_after_save_rating_success action and mrp_after_delete_rating_success action to use a rating entry array. * New: Added mrp_templates_dir filter to modify the template directory * Bug: Fixed widgets not saving the rating form option correctly * Bug: Fixed missing stripslashes() on custom field values * Bug: Improved sanitization of custom fields using wp_kses() to only allow certain HTML tags * Bug: Fixed custom field values not showing in email notifications * Bug: Added missing show_count shortcode attribute to the [mrp_rating_item_results] shortcode which is used only for the no_options layout * New: Added after_count and before_count shortcode attributes to the [mrp_rating_item_results] shortcode * Important: Removed API functions calculate_rating_entry_result and calculate_rating_entry_result2. Use mrp_calculate_rating_entry_result() function instead. * Important: Removed mrp_after_save_rating_success filter. Use mrp_after_save_rating_entry_success instead. * Important: Removed mrp_after_rating_item_validation, mrp_after_custom_field_validation, mrp_after_review_fields_validation and mrp_after_rating_form_validation filters. Replaced with mrp_before_rating_entry_validation and mrp_after_rating_entry_validation filters. * New: Added ID to row actions to improve usability in wp-list-tables for rating results, rating entries, rating items, rating forms and custom fields * New: Added ID of WordPress users to the rating entries table in wp-admin * New: Added count of entries for each rating form in rating forms page * New: Added new API function get_rating_forms() * Bug: Fixed {post_permalink} template tag for notification emails * New: Added mrp_rating_moderation_notification_template_tags and mrp_rating_approved_notification_template_tags in case you want to add your own e-mail templatre tags for substituting values e.g. {site_name} * Tweak: Updated the plugin updater and licensing settings to cater for add-ons = 5.1 (08/07/2016) = * New: Added schema.org reviews for the [mrp_rating_entry_details_list] shortcode * New: Added new mrp_after_delete_rating_form hook * New: Added count_entries rating result post meta field * Bug: Fixed stray tr in rating-entry-details-list.php template file * Bug: Some JS fixes based on JSLint and also updated some jQuery selectors based on attribute values to be surrounded in quotes * Bug: Fixed default rating item value not being set in the WP comment form * Bug: Fixed e-mail label for HTML error in rating-form.php template file: