Yasr – Yet Another Stars Rating - Version 0.4.0

Version Description

  • Popup shortcode creatore it's now tabbed and got a link to the new doc
  • Minor changes and bugfixes
Download this release

Release Info

Developer Dudo
Plugin Icon 128x128 Yasr – Yet Another Stars Rating
Version 0.4.0
Comparing to
See all releases

Code changes from version 0.3.9 to 0.4.0

css/yasr.css CHANGED
@@ -10,16 +10,29 @@
10
  }
11
 
12
  /*** Top menu navigation ***/
13
- h2.nav-tab-wrapper, h3.nav-tab-wrapper {
14
  border-bottom: none !important;
15
  }
16
 
17
  .nav-tab-active, .nav-tab-active:hover {
18
- background-color: white !important;
19
  }
20
 
21
  /*** End top navigation ***/
22
 
 
 
 
 
 
 
 
 
 
 
 
 
 
23
 
24
  @media (min-width: 972px) {
25
 
@@ -225,6 +238,13 @@ h2.nav-tab-wrapper, h3.nav-tab-wrapper {
225
  /*** End rules for multi set admin page ***/
226
 
227
 
 
 
 
 
 
 
 
228
  #yasr-log-container {
229
  width: 98%;
230
  }
10
  }
11
 
12
  /*** Top menu navigation ***/
13
+ .yasr-no-underline {
14
  border-bottom: none !important;
15
  }
16
 
17
  .nav-tab-active, .nav-tab-active:hover {
18
+ background-color: white ;
19
  }
20
 
21
  /*** End top navigation ***/
22
 
23
+ /*** Tinymce popup ***/
24
+
25
+
26
+ .yasr-underline {
27
+ border-bottom: 1px solid #CCC !important;
28
+ }
29
+
30
+ #yasr-tinypopup-link-doc {
31
+ float: right;
32
+ font-size: 12px;
33
+ }
34
+
35
+ /*** End tinymce popup ***/
36
 
37
  @media (min-width: 972px) {
38
 
238
  /*** End rules for multi set admin page ***/
239
 
240
 
241
+
242
+ /*** Popup in tinymce ***/
243
+
244
+
245
+
246
+
247
+
248
  #yasr-log-container {
249
  width: 98%;
250
  }
js/addButton_tinymcs.js CHANGED
@@ -4,10 +4,10 @@ jQuery(document).ready(function() {
4
  init : function(ed, url) {
5
  // Register command for when button is clicked
6
  ed.addCommand('yasr_insert_shortcode', function() {
7
-
8
- jQuery('#yasr-form').dialog({
9
  title: 'Insert YASR shortcode',
10
- width: 'auto', // overcomes width:'auto' and maxWidth bug
11
  maxWidth: 600,
12
  height: 'auto',
13
  modal: true,
@@ -39,8 +39,8 @@ jQuery(document).ready(function() {
39
 
40
  var response=button_content;
41
 
42
- var table = jQuery(response).find('yasr-form');
43
  jQuery(response).appendTo('body').hide();
 
44
  });
45
  });
46
 
4
  init : function(ed, url) {
5
  // Register command for when button is clicked
6
  ed.addCommand('yasr_insert_shortcode', function() {
7
+
8
+ jQuery('#yasr-tinypopup-form').dialog({
9
  title: 'Insert YASR shortcode',
10
+ width: 500, // overcomes width:'auto' and maxWidth bug
11
  maxWidth: 600,
12
  height: 'auto',
13
  modal: true,
39
 
40
  var response=button_content;
41
 
 
42
  jQuery(response).appendTo('body').hide();
43
+
44
  });
45
  });
46
 
lib/yasr-ajax-functions.php CHANGED
@@ -319,85 +319,126 @@ if ( ! defined( 'ABSPATH' ) ) exit('You\'re not allowed to see this page'); // E
319
 
320
  ?>
321
 
322
- <div id="yasr-form">
323
-
324
- <table id="yasr-table" class="form-table">
325
- <tr>
326
- <th><label for="yasr-overall"><?php _e("Overall Rating / Review"); ?></label></th>
327
- <td><input type="button" class="button-primary" id="yasr-overall" name="yasr-overall" value="Insert Overall Rating" /><br />
328
- <small><?php _e("Insert Overall Rating / Review for this post"); ?></small></td>
329
- </tr>
330
- <tr>
331
- <th><label for="yasr-id"><?php _e("Visitor Votes"); ?></label></th>
332
- <td><input type="button" class="button-primary" name="yasr-visitor-votes" id="yasr-visitor-votes" value="Insert Visitor Votes"/><br />
333
- <small><?php _e("Insert the ability for your visitor to vote"); ?></small></td>
334
- </tr>
335
-
336
- <?php if ($n_multi_set>1) { //If multiple Set are found ?>
337
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
338
  <tr>
339
- <th><label for="yasr-size"><?php _e("If you want to insert a multi-set, pick one:"); ?></label></th>
340
- <td>
341
- <?php foreach ($multi_set as $name) { ?>
342
- <input type="radio" value="<?php echo $name->set_id ?>" name="yasr_tinymce_pick_set" class="yasr_tinymce_select_set"><?php echo $name->set_name ?>
343
- <br />
344
- <?php } //End foreach ?>
345
- <small><?php _e("Choose wich set you want to insert."); ?></small>
346
- </td>
347
  </tr>
348
 
349
- <?php } //End if
 
 
 
 
350
 
351
- elseif ($n_multi_set==1) { ?>
352
  <tr>
353
- <th><label for="yasr-size"><?php _e("Insert Multiset:"); ?></label></th>
354
- <td>
355
- <?php foreach ($multi_set as $name) { ?>
356
- <button type="button" class="button-primary" id="yasr-single-set" name="yasr-single-set" value="<?php echo $name->set_id ?>" >Insert Multiple Set</button><br />
357
- <small><?php _e("Insert multiple set <?php echo $name->set_name ?> in this post ?"); ?></small>
358
- <?php } //End foreach ?>
359
- </td>
360
  </tr>
361
- <?php
362
- }
363
- //End elseif ?>
364
-
365
- <tr>
366
- <th><label for="yasr-10-overall"><?php _e("Top 10 overall ratings"); ?></label></th>
367
- <td><input type="button" class="button-primary" name="yasr-top-10-overall-rating" id="yasr-top-10-overall-rating" value="Insert Top 10 highest rated"/><br />
368
- <small><?php _e("Insert Top 10 highest rated by post author"); ?></small></td>
369
- </tr>
370
-
371
- <tr>
372
- <th><label for="yasr-10-highest-most-rated"><?php _e("Top 10 by visitors"); ?></label></th>
373
- <td><input type="button" class="button-primary" name="yasr-10-highest-most-rated" id="yasr-10-highest-most-rated" value="Insert Top 10 posts by visitors"/><br />
374
- <small><?php _e("Insert Top 10 most or higher rated posts from visitors"); ?></small></td>
375
- </tr>
376
-
377
- <tr>
378
- <th><label for="yasr-5-active-reviewers"><?php _e("Most active reviewers"); ?></label></th>
379
- <td><input type="button" class="button-primary" name="yasr-5-active-reviewers" id="yasr-5-active-reviewers" value="Insert Top 5 most active reviewers"/><br />
380
- <small><?php _e("Insert Top 5 active reviewers"); ?></small></td>
381
- </tr>
382
-
383
- <tr>
384
- <th><label for="yasr-10-active-users"><?php _e("Most active users"); ?></label></th>
385
- <td><input type="button" class="button-primary" name="yasr-top-10-active-users" id="yasr-top-10-active-users" value="Insert Top 10 most active users"/><br />
386
- <small><?php _e("Insert Top 10 active users in visitor ratings"); ?></small></td>
387
- </tr>
388
-
389
- </table>
390
  </div>
391
 
392
  <script>
393
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
394
  // Add shortcode for overall rating
395
  jQuery('#yasr-overall').on("click", function(){
396
  var shortcode = '[yasr_overall_rating]';
397
  // inserts the shortcode into the active editor
398
  tinyMCE.activeEditor.execCommand('mceInsertContent', 0, shortcode);
399
  // closes jqueryui
400
- jQuery('#yasr-form').dialog('close');
401
  });
402
 
403
  //Add shortcode for visitors rating
@@ -406,7 +447,7 @@ if ( ! defined( 'ABSPATH' ) ) exit('You\'re not allowed to see this page'); // E
406
  // inserts the shortcode into the active editor
407
  tinyMCE.activeEditor.execCommand('mceInsertContent', 0, shortcode);
408
  // closes Thickbox
409
- jQuery('#yasr-form').dialog('close');
410
  });
411
 
412
  <?php if ($n_multi_set>1) { ?>
@@ -420,7 +461,7 @@ if ( ! defined( 'ABSPATH' ) ) exit('You\'re not allowed to see this page'); // E
420
  // inserts the shortcode into the active editor
421
  tinyMCE.activeEditor.execCommand('mceInsertContent', 0, shortcode);
422
  // closes jqueryui
423
- jQuery('#yasr-form').dialog('close');
424
  });
425
 
426
  <?php } //End if
@@ -436,7 +477,7 @@ if ( ! defined( 'ABSPATH' ) ) exit('You\'re not allowed to see this page'); // E
436
  // inserts the shortcode into the active editor
437
  tinyMCE.activeEditor.execCommand('mceInsertContent', 0, shortcode);
438
  // closes jqueryui
439
- jQuery('#yasr-form').dialog('close');
440
  });
441
 
442
  <?php
@@ -449,7 +490,7 @@ if ( ! defined( 'ABSPATH' ) ) exit('You\'re not allowed to see this page'); // E
449
  // inserts the shortcode into the active editor
450
  tinyMCE.activeEditor.execCommand('mceInsertContent', 0, shortcode);
451
  // closes jqueryui
452
- jQuery('#yasr-form').dialog('close');
453
  });
454
 
455
  // Add shortcode for 10 highest most rated
@@ -458,7 +499,7 @@ if ( ! defined( 'ABSPATH' ) ) exit('You\'re not allowed to see this page'); // E
458
  // inserts the shortcode into the active editor
459
  tinyMCE.activeEditor.execCommand('mceInsertContent', 0, shortcode);
460
  // closes jqueryui
461
- jQuery('#yasr-form').dialog('close');
462
  });
463
 
464
  // Add shortcode for top 5 active reviewer
@@ -467,7 +508,7 @@ if ( ! defined( 'ABSPATH' ) ) exit('You\'re not allowed to see this page'); // E
467
  // inserts the shortcode into the active editor
468
  tinyMCE.activeEditor.execCommand('mceInsertContent', 0, shortcode);
469
  // closes jqueryui
470
- jQuery('#yasr-form').dialog('close');
471
  });
472
 
473
  // Add shortcode for top 10 active users
@@ -476,7 +517,7 @@ if ( ! defined( 'ABSPATH' ) ) exit('You\'re not allowed to see this page'); // E
476
  // inserts the shortcode into the active editor
477
  tinyMCE.activeEditor.execCommand('mceInsertContent', 0, shortcode);
478
  // closes jqueryui
479
- jQuery('#yasr-form').dialog('close');
480
  });
481
 
482
  </script>
@@ -931,6 +972,8 @@ add_action( 'wp_ajax_yasr_change_log_page', 'yasr_change_log_page_callback' );
931
  } //End callback function
932
 
933
 
 
 
934
  /****** Order yasr_multi_chart ******/
935
 
936
  add_action ( 'wp_ajax_yasr_multi_chart_most_highest', 'yasr_multi_chart_most_highest_callback' );
@@ -1049,4 +1092,5 @@ add_action( 'wp_ajax_yasr_change_log_page', 'yasr_change_log_page_callback' );
1049
 
1050
  } //End function
1051
 
 
1052
  ?>
319
 
320
  ?>
321
 
322
+ <div id="yasr-tinypopup-form">
 
 
 
 
 
 
 
 
 
 
 
 
 
 
323
 
324
+ <h2 class="nav-tab-wrapper yasr-underline">
325
+ <a href="#" id="yasr-link-tab-main" class="nav-tab nav-tab-active">Main</a>
326
+ <a href="#" id="yasr-link-tab-charts" class="nav-tab">Charts</a>
327
+
328
+ <a href="https://wordpress.org/plugins/yet-another-stars-rating/faq/" target="_blank" id="yasr-tinypopup-link-doc">Read the doc</a>
329
+
330
+ </h2>
331
+
332
+ <div id="yasr-content-tab-main">
333
+
334
+ <table id="yasr-table-tiny-popup-main" class="form-table">
335
+ <tr>
336
+ <th><label for="yasr-overall"><?php _e("Overall Rating / Review"); ?></label></th>
337
+ <td><input type="button" class="button-primary" id="yasr-overall" name="yasr-overall" value="Insert Overall Rating" /><br />
338
+ <small><?php _e("Insert Overall Rating / Review for this post"); ?></small></td>
339
+ </tr>
340
+ <tr>
341
+ <th><label for="yasr-id"><?php _e("Visitor Votes"); ?></label></th>
342
+ <td><input type="button" class="button-primary" name="yasr-visitor-votes" id="yasr-visitor-votes" value="Insert Visitor Votes"/><br />
343
+ <small><?php _e("Insert the ability for your visitor to vote"); ?></small></td>
344
+ </tr>
345
+
346
+ <?php if ($n_multi_set>1) { //If multiple Set are found ?>
347
+
348
+ <tr>
349
+ <th><label for="yasr-size"><?php _e("If you want to insert a multi-set, pick one:"); ?></label></th>
350
+ <td>
351
+ <?php foreach ($multi_set as $name) { ?>
352
+ <input type="radio" value="<?php echo $name->set_id ?>" name="yasr_tinymce_pick_set" class="yasr_tinymce_select_set"><?php echo $name->set_name ?>
353
+ <br />
354
+ <?php } //End foreach ?>
355
+ <small><?php _e("Choose wich set you want to insert."); ?></small>
356
+ </td>
357
+ </tr>
358
+
359
+ <?php } //End if
360
+
361
+ elseif ($n_multi_set==1) { ?>
362
+ <tr>
363
+ <th><label for="yasr-size"><?php _e("Insert Multiset:"); ?></label></th>
364
+ <td>
365
+ <?php foreach ($multi_set as $name) { ?>
366
+ <button type="button" class="button-primary" id="yasr-single-set" name="yasr-single-set" value="<?php echo $name->set_id ?>" >Insert Multiple Set</button><br />
367
+ <small><?php _e("Insert multiple set <?php echo $name->set_name ?> in this post ?"); ?></small>
368
+ <?php } //End foreach ?>
369
+ </td>
370
+ </tr>
371
+ <?php
372
+ }
373
+ //End elseif ?>
374
+ </table>
375
+
376
+ </div>
377
+
378
+ <div id="yasr-content-tab-charts" style="display:none">
379
+
380
+ <table id="yasr-table-tiny-popup-charts" class="form-table">
381
  <tr>
382
+ <th><label for="yasr-10-overall"><?php _e("Top 10 overall ratings"); ?></label></th>
383
+ <td><input type="button" class="button-primary" name="yasr-top-10-overall-rating" id="yasr-top-10-overall-rating" value="Insert Top 10 highest rated"/><br />
384
+ <small><?php _e("Insert Top 10 highest rated by post author"); ?></small></td>
 
 
 
 
 
385
  </tr>
386
 
387
+ <tr>
388
+ <th><label for="yasr-10-highest-most-rated"><?php _e("Top 10 by visitors"); ?></label></th>
389
+ <td><input type="button" class="button-primary" name="yasr-10-highest-most-rated" id="yasr-10-highest-most-rated" value="Insert Top 10 posts by visitors"/><br />
390
+ <small><?php _e("Insert Top 10 most or higher rated posts from visitors"); ?></small></td>
391
+ </tr>
392
 
 
393
  <tr>
394
+ <th><label for="yasr-5-active-reviewers"><?php _e("Most active reviewers"); ?></label></th>
395
+ <td><input type="button" class="button-primary" name="yasr-5-active-reviewers" id="yasr-5-active-reviewers" value="Insert Top 5 most active reviewers"/><br />
396
+ <small><?php _e("Insert Top 5 active reviewers"); ?></small></td>
 
 
 
 
397
  </tr>
398
+
399
+ <tr>
400
+ <th><label for="yasr-10-active-users"><?php _e("Most active users"); ?></label></th>
401
+ <td><input type="button" class="button-primary" name="yasr-top-10-active-users" id="yasr-top-10-active-users" value="Insert Top 10 most active users"/><br />
402
+ <small><?php _e("Insert Top 10 active users in visitor ratings"); ?></small></td>
403
+ </tr>
404
+
405
+ </table>
406
+
407
+ </div>
408
+
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
409
  </div>
410
 
411
  <script>
412
 
413
+ // When click on chart chart hide tab-main and show tab-charts
414
+ jQuery('#yasr-link-tab-charts').on("click", function(){
415
+
416
+ jQuery('#yasr-link-tab-main').removeClass('nav-tab-active');
417
+ jQuery('#yasr-link-tab-charts').addClass('nav-tab-active');
418
+
419
+ jQuery('#yasr-content-tab-main').hide();
420
+ jQuery('#yasr-content-tab-charts').show();
421
+
422
+ });
423
+
424
+ // When click on main tab hide tab-main and show tab-charts
425
+ jQuery('#yasr-link-tab-main').on("click", function(){
426
+
427
+ jQuery('#yasr-link-tab-charts').removeClass('nav-tab-active');
428
+ jQuery('#yasr-link-tab-main').addClass('nav-tab-active');
429
+
430
+ jQuery('#yasr-content-tab-charts').hide();
431
+ jQuery('#yasr-content-tab-main').show();
432
+
433
+ });
434
+
435
  // Add shortcode for overall rating
436
  jQuery('#yasr-overall').on("click", function(){
437
  var shortcode = '[yasr_overall_rating]';
438
  // inserts the shortcode into the active editor
439
  tinyMCE.activeEditor.execCommand('mceInsertContent', 0, shortcode);
440
  // closes jqueryui
441
+ jQuery('#yasr-tinypopup-form').dialog('close');
442
  });
443
 
444
  //Add shortcode for visitors rating
447
  // inserts the shortcode into the active editor
448
  tinyMCE.activeEditor.execCommand('mceInsertContent', 0, shortcode);
449
  // closes Thickbox
450
+ jQuery('#yasr-tinypopup-form').dialog('close');
451
  });
452
 
453
  <?php if ($n_multi_set>1) { ?>
461
  // inserts the shortcode into the active editor
462
  tinyMCE.activeEditor.execCommand('mceInsertContent', 0, shortcode);
463
  // closes jqueryui
464
+ jQuery('#yasr-tinypopup-form').dialog('close');
465
  });
466
 
467
  <?php } //End if
477
  // inserts the shortcode into the active editor
478
  tinyMCE.activeEditor.execCommand('mceInsertContent', 0, shortcode);
479
  // closes jqueryui
480
+ jQuery('#yasr-tinypopup-form').dialog('close');
481
  });
482
 
483
  <?php
490
  // inserts the shortcode into the active editor
491
  tinyMCE.activeEditor.execCommand('mceInsertContent', 0, shortcode);
492
  // closes jqueryui
493
+ jQuery('#yasr-tinypopup-form').dialog('close');
494
  });
495
 
496
  // Add shortcode for 10 highest most rated
499
  // inserts the shortcode into the active editor
500
  tinyMCE.activeEditor.execCommand('mceInsertContent', 0, shortcode);
501
  // closes jqueryui
502
+ jQuery('#yasr-tinypopup-form').dialog('close');
503
  });
504
 
505
  // Add shortcode for top 5 active reviewer
508
  // inserts the shortcode into the active editor
509
  tinyMCE.activeEditor.execCommand('mceInsertContent', 0, shortcode);
510
  // closes jqueryui
511
+ jQuery('#yasr-tinypopup-form').dialog('close');
512
  });
513
 
514
  // Add shortcode for top 10 active users
517
  // inserts the shortcode into the active editor
518
  tinyMCE.activeEditor.execCommand('mceInsertContent', 0, shortcode);
519
  // closes jqueryui
520
+ jQuery('#yasr-tinypopup-form').dialog('close');
521
  });
522
 
523
  </script>
972
  } //End callback function
973
 
974
 
975
+ /****** Order yasr_multi_chart ******/
976
+
977
  /****** Order yasr_multi_chart ******/
978
 
979
  add_action ( 'wp_ajax_yasr_multi_chart_most_highest', 'yasr_multi_chart_most_highest_callback' );
1092
 
1093
  } //End function
1094
 
1095
+
1096
  ?>
readme.txt CHANGED
@@ -3,7 +3,7 @@ Donate link: https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_i
3
  Tags: Rating, Review, Star, Snippet, Rich snippet, Schema, Schema.org, Serp
4
  Requires at least: 3.5
5
  Tested up to: 3.9.1
6
- Stable tag: 0.3.9
7
  License: GPL2
8
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
9
 
@@ -45,28 +45,30 @@ If with gd-star-rating you're using a different number of stars from the default
45
  == Frequently Asked Questions ==
46
 
47
  = What is "Overall Rating"? =
48
- It's the vote put from who write the review: readers can see this vote in read-only. Reviewer can vote using the box on the top rigth when writing a new articole or post (he / she must have at least "Author" role). Remember to insert this shortcode **[yasr_overall_rating]** to make appear where you want. You can choose to make it appear just in a single post/page or in archive pages too (e.g. default Index, category pages, etc)
49
 
50
  = What is "Visitor Rating"? =
51
- It's the vote that allows your visitors to vote: just paste this shortcode **[yasr_visitor_votes]** where you want the stars to appear. This works only in single post or pages
52
 
53
  = What is "Multi Set"? =
54
- It's the feature that make YASR awesome. Multisets give the opportunity to score different aspects for each review: for example, if you're reviewing a videogame, you can create the aspects "Graphics", "Gameplay", "Story", etc. and give a vote for each one. To create a set, just go in "Settings" -> "Yet Another Stars Rating: Settings" and click on the "Multi Sets" tab. To insert it into a post, just paste the shortcode that YASR will create for you.
55
 
56
  = What is "Top 10 overall ratings" ? =
57
- It's the chart of the 10 highest rated item from reviewer. To insert it into a post or page, just paste this shortcode **[yasr_top_ten_highest_rated]**
58
 
59
  = What is "Top 10 by visitors" ? =
60
- This is 2 charts in 1. Infact, this chart will be display both the most rated posts/pages or the highest rated posts/pages. In order to appear in this chart item must be rated at least twice. Paste this shortcode to make appear where you want **[yasr_most_or_highest_rated_posts]**
 
 
61
 
62
  = What is "Most active reviewers" ? =
63
- If in your site there are more than 1 person writing reviews, this chart will show up the most 5 active reviewer. Shortcode is **[yasr_top_5_reviewers]**
64
 
65
  = What is Most "active users" ? =
66
- When a visitor (logged in or not) rates a post/page, rating are stored in the database. This chart will show the 10 most active users; show up login name if was logged in, "Anonymous" otherwise. The shortcode : **[yasr_top_ten_active_users]**
67
 
68
  = Wait, wait! Do I need to keep in mind all this shortcode? =
69
- Of course no: you can easly add it on visual editor clicking on the yellow star and then choose what to insert
70
 
71
  == Screenshots ==
72
  1. Example of yasr in a videogame review
@@ -74,6 +76,10 @@ Of course no: you can easly add it on visual editor clicking on the yellow star
74
 
75
  == Changelog ==
76
 
 
 
 
 
77
  = 0.3.9 =
78
  * Fixed page exclusion
79
 
3
  Tags: Rating, Review, Star, Snippet, Rich snippet, Schema, Schema.org, Serp
4
  Requires at least: 3.5
5
  Tested up to: 3.9.1
6
+ Stable tag: 0.4.0
7
  License: GPL2
8
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
9
 
45
  == Frequently Asked Questions ==
46
 
47
  = What is "Overall Rating"? =
48
+ It is the vote given by who writes the review: readers are able to see this vote in read-only mode. Reviewer can vote using the box on the top rigth when writing a new article or post (he or she must have at least the "Author" role). Remember to insert this shortcode **[yasr_overall_rating]** to make it appear where you like. You can choose to make it appear just in a single post/page or in archive pages too (e.g. default Index, category pages, etc).
49
 
50
  = What is "Visitor Rating"? =
51
+ It is the vote that allows your visitors to vote: just paste this shortcode **[yasr_visitor_votes]** where you want the stars to appear. This works only in single posts or pages.
52
 
53
  = What is "Multi Set"? =
54
+ It is the feature that makes YASR awesome. Multisets give the opportunity to score different aspects for each review: for example, if you're reviewing a videogame, you can create the aspects "Graphics", "Gameplay", "Story", etc. and give a vote for each one. To create a set, just go in "Settings" -> "Yet Another Stars Rating: Settings" and click on the "Multi Sets" tab. To insert it into a post, just paste the shortcode that YASR will create for you.
55
 
56
  = What is "Top 10 overall ratings" ? =
57
+ It is the 10 highest rated item chart by reviewer. In order to insert it into a post or page, just paste this shortcode **[yasr_top_ten_highest_rated]**
58
 
59
  = What is "Top 10 by visitors" ? =
60
+ This is 2 charts in 1. Infact, this chart shows both the most rated posts/pages or the highest rated posts/pages.
61
+ For an item to appear in this chart, it has to be rated twice at least.
62
+ Paste this shortcode to make it appear where you want **[yasr_most_or_highest_rated_posts]**
63
 
64
  = What is "Most active reviewers" ? =
65
+ If in your site there are more than 1 person writing reviews, this chart will show the 5 most active reviewers. Shortcode is **[yasr_top_5_reviewers]**
66
 
67
  = What is Most "active users" ? =
68
+ When a visitor (logged in or not) rates a post/page, his rating is stored in the database. This chart will show the 10 most active users, displaying the login name if logged in or "Anonymous" otherwise. The shortcode : **[yasr_top_ten_active_users]**
69
 
70
  = Wait, wait! Do I need to keep in mind all this shortcode? =
71
+ Of course not: you can easily add it on the visual editor just by clicking on the yellow star and then choose what to insert.
72
 
73
  == Screenshots ==
74
  1. Example of yasr in a videogame review
76
 
77
  == Changelog ==
78
 
79
+ = 0.4.0 =
80
+ * Popup shortcode creatore it's now tabbed and got a link to the new doc
81
+ * Minor changes and bugfixes
82
+
83
  = 0.3.9 =
84
  * Fixed page exclusion
85
 
yasr-metabox-overall-rating.php CHANGED
@@ -10,6 +10,8 @@ if ( ! defined( 'ABSPATH' ) ) exit('You\'re not allowed to see this page'); // E
10
 
11
  add_action( 'admin_footer', 'yasr_overall_rating_javascript' );
12
 
 
 
13
  ?>
14
 
15
  <span id="yasr_rateit_actual_overall_rating">
@@ -28,8 +30,18 @@ if ( ! defined( 'ABSPATH' ) ) exit('You\'re not allowed to see this page'); // E
28
 
29
  <div>
30
 
31
- <span id="yasr_rateit_overall_value"></span>
32
 
 
 
 
 
 
 
 
 
 
 
33
  </div>
34
 
35
  <?php
10
 
11
  add_action( 'admin_footer', 'yasr_overall_rating_javascript' );
12
 
13
+ $option = get_option('yasr_general_options');
14
+
15
  ?>
16
 
17
  <span id="yasr_rateit_actual_overall_rating">
30
 
31
  <div>
32
 
33
+ <span id="yasr_rateit_overall_value"></span>
34
 
35
+ <?php
36
+
37
+ if($option['auto_insert_enabled'] == 0) {
38
+
39
+ echo "Remember to insert this shoortcode <strong>[yasr_overall_rating]</strong> where you want to display this rating";
40
+
41
+ }
42
+
43
+ ?>
44
+
45
  </div>
46
 
47
  <?php
yasr-settings-page.php CHANGED
@@ -52,7 +52,7 @@ if ( !current_user_can( 'manage_options' ) ) {
52
 
53
  ?>
54
 
55
- <h2 class="nav-tab-wrapper">
56
  <a href="?page=yasr_settings_page&tab=general_settings" class="nav-tab <?php if ($active_tab == 'general_settings') echo 'nav-tab-active'; ?>" > General Settings </a>
57
  <a href="?page=yasr_settings_page&tab=manage_multi" class="nav-tab <?php if ($active_tab == 'manage_multi') echo 'nav-tab-active'; ?>" > Multi Sets </a>
58
  </h2>
@@ -272,7 +272,7 @@ if ( !current_user_can( 'manage_options' ) ) {
272
  <br />
273
 
274
  <a href="https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=AXE284FYMNWDC">
275
- <?php echo("<img src=\"" . YASR_IMG_DIR . "\"/paypal.png>"); ?>
276
  </a>
277
 
278
  </div>
52
 
53
  ?>
54
 
55
+ <h2 class="nav-tab-wrapper yasr-no-underline">
56
  <a href="?page=yasr_settings_page&tab=general_settings" class="nav-tab <?php if ($active_tab == 'general_settings') echo 'nav-tab-active'; ?>" > General Settings </a>
57
  <a href="?page=yasr_settings_page&tab=manage_multi" class="nav-tab <?php if ($active_tab == 'manage_multi') echo 'nav-tab-active'; ?>" > Multi Sets </a>
58
  </h2>
272
  <br />
273
 
274
  <a href="https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=AXE284FYMNWDC">
275
+ <?php echo("<img src=" . YASR_IMG_DIR . "/paypal.png>"); ?>
276
  </a>
277
 
278
  </div>
yet-another-stars-rating.php CHANGED
@@ -3,7 +3,7 @@
3
  * Plugin Name: Yet Another Stars Rating
4
  * Plugin URI: http://wordpress.org/plugins/yet-another-stars-rating/
5
  * Description: Rating system with rich snippets
6
- * Version: 0.3.9
7
  * Author: Dario Curvino
8
  * Author URI: http://profiles.wordpress.org/dudo/
9
  * License: GPL2
@@ -28,7 +28,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>
28
  */
29
 
30
 
31
- define('YASR_VERSION_NUM', '0.3.9');
32
 
33
  //Plugin absolute path
34
  define( "YASR_ABSOLUTE_PATH", dirname(__FILE__) );
@@ -64,7 +64,7 @@ require (YASR_ABSOLUTE_PATH . '/lib/yasr-shortcode-functions.php');
64
  $version_installed = get_option('yasr-version') ;
65
 
66
 
67
- //If this is a fresh new installation or version < 0.2.0
68
 
69
  if (!$version_installed ) {
70
 
3
  * Plugin Name: Yet Another Stars Rating
4
  * Plugin URI: http://wordpress.org/plugins/yet-another-stars-rating/
5
  * Description: Rating system with rich snippets
6
+ * Version: 0.4.0
7
  * Author: Dario Curvino
8
  * Author URI: http://profiles.wordpress.org/dudo/
9
  * License: GPL2
28
  */
29
 
30
 
31
+ define('YASR_VERSION_NUM', '0.4.0');
32
 
33
  //Plugin absolute path
34
  define( "YASR_ABSOLUTE_PATH", dirname(__FILE__) );
64
  $version_installed = get_option('yasr-version') ;
65
 
66
 
67
+ //If this is a fresh new installation
68
 
69
  if (!$version_installed ) {
70