Yet Another Related Posts Plugin (YARPP) - Version 5.2.1

Version Description

(2020-07-20) = * Enhancement: Don't recommend switching database engine unless necessary for fulltext indexes.

Download this release

Release Info

Developer jeffparker
Plugin Icon 128x128 Yet Another Related Posts Plugin (YARPP)
Version 5.2.1
Comparing to
See all releases

Code changes from version 5.2.0 to 5.2.1

Files changed (3) hide show
  1. includes/yarpp_myisam_notice.php +30 -23
  2. readme.txt +7 -3
  3. yarpp.php +2 -2
includes/yarpp_myisam_notice.php CHANGED
@@ -55,28 +55,32 @@ if ( !(bool) yarpp_get_option(YARPP_DB_Options::YARPP_MYISAM_OVERRIDE) && $yarpp
55
  </a>
56
  </p>
57
  <div id="yarpp_fulltext_details" class="hidden">
58
- <p><?php
59
- printf(
60
- esc_html__('Because fulltext indexing is not supported by your current table engine, "%1$s", YARPP cannot compare posts based on their titles or bodies.','yarpp'),
61
- 'InnoDB',
62
- '5.6.4',
63
- '<code>' . $wpdb->posts . '</code>',
64
- 'MyISAM'
65
- );
66
- ?>
67
- </p>
68
- <p><?php
69
- printf(
70
- esc_html__('Please contact your host about updating MySQL to at latest version %1$s, or run the following SQL code on your MySQL client (eg PHPMyAdmin) or terminal:', 'yarpp'),
71
- '5.6.4'
72
- );
73
- ?>
74
- </p>
75
- <code class="yarpp_separated">ALTER TABLE `<?php echo $wpdb->posts;?>` ENGINE = MyISAM;</code>
76
- <p><?php
77
- esc_html_e('After you have done that, click the button below to enable comparing titles and bodies using "fulltext indexes."','yarpp');
78
- ?>
79
- </p>
 
 
 
 
80
  <form method="post" class="yarpp_separated">
81
  <input type='submit' class='button' name='myisam_override' value='Create fulltext indexes'/>
82
  </form>
@@ -86,7 +90,9 @@ if ( !(bool) yarpp_get_option(YARPP_DB_Options::YARPP_MYISAM_OVERRIDE) && $yarpp
86
  );
87
  ?>
88
  </p>
89
- <p><?php
 
 
90
  printf(
91
  esc_html__('See MySQL %1$sstorage engines%2$s documentation for details on MySQL engines.','yarpp'),
92
  '<a href="https://dev.mysql.com/doc/refman/8.0/en/storage-engines.html" target="_blank">',
@@ -94,6 +100,7 @@ if ( !(bool) yarpp_get_option(YARPP_DB_Options::YARPP_MYISAM_OVERRIDE) && $yarpp
94
  );
95
  ?>
96
  </p>
 
97
  </div>
98
  </div>
99
  <?php
55
  </a>
56
  </p>
57
  <div id="yarpp_fulltext_details" class="hidden">
58
+ <?php if ( $database_supports_fulltext_indexes ){ ?>
59
+ <p><?php esc_html_e('YARPP can automatically create "fulltext indexes" to enable comparing posts based on titles and bodies. To do so, click the button below.');?></p>
60
+ <?php } else { ?>
61
+ <p><?php
62
+ printf(
63
+ esc_html__('Because fulltext indexing is not supported by your current table engine, "%1$s", YARPP cannot compare posts based on their titles or bodies.','yarpp'),
64
+ 'InnoDB',
65
+ '5.6.4',
66
+ '<code>' . $wpdb->posts . '</code>',
67
+ 'MyISAM'
68
+ );
69
+ ?>
70
+ </p>
71
+ <p><?php
72
+ printf(
73
+ esc_html__('Please contact your host about updating MySQL to at latest version %1$s, or run the following SQL code on your MySQL client (eg PHPMyAdmin) or terminal:', 'yarpp'),
74
+ '5.6.4'
75
+ );
76
+ ?>
77
+ </p>
78
+ <code class="yarpp_separated">ALTER TABLE `<?php echo $wpdb->posts;?>` ENGINE = MyISAM;</code>
79
+ <p><?php
80
+ esc_html_e('After you have done that, click the button below to enable comparing titles and bodies using "fulltext indexes."','yarpp');
81
+ ?>
82
+ </p>
83
+ <?php } ?>
84
  <form method="post" class="yarpp_separated">
85
  <input type='submit' class='button' name='myisam_override' value='Create fulltext indexes'/>
86
  </form>
90
  );
91
  ?>
92
  </p>
93
+ <?php if( ! $database_supports_fulltext_indexes){ ?>
94
+ <p>
95
+ <?php
96
  printf(
97
  esc_html__('See MySQL %1$sstorage engines%2$s documentation for details on MySQL engines.','yarpp'),
98
  '<a href="https://dev.mysql.com/doc/refman/8.0/en/storage-engines.html" target="_blank">',
100
  );
101
  ?>
102
  </p>
103
+ <?php } ?>
104
  </div>
105
  </div>
106
  <?php
readme.txt CHANGED
@@ -5,7 +5,7 @@ Requires at least: 3.7
5
  Requires PHP: 5.3
6
  License: GPLv2 or later
7
  Tested up to: 5.4
8
- Stable tag: 5.2.0
9
 
10
  Display a list of related posts on your site based on a powerful unique algorithm. Optionally, earn money by including sponsored content.
11
 
@@ -25,7 +25,8 @@ Yet Another Related Posts Plugin (YARPP) displays pages, posts, and custom post
25
 
26
  **YARPP Algorithm Explained**
27
  -------------------------------------------
28
- [wpvideo 0n2TSzkb]
 
29
 
30
  **Trusted since 2008**
31
  -------------------------------------------
@@ -270,6 +271,9 @@ add_action(
270
  `
271
 
272
  == Changelog ==
 
 
 
273
  = 5.2.0 (2020-07-20) =
274
  * Enhancement: Adds support for InnoDb fulltext search! One of our most requested features. Fulltext indexing is supported in MyISAM or InnoDB with MySQL 5.6.4 and higher.
275
  * Enhancement: Optimized database queries, resulting in ~2x speed improvement in some queries.
@@ -958,6 +962,6 @@ After a break of many years, the plugin is 100% supported now that the baton has
958
  * Initial upload
959
 
960
  == Upgrade Notice ==
961
- = 5.2.0 =
962
  We update this plugin regularly so we can make it better for you. Update to the latest version for all of the available features and improvements. Thank you for using YARPP!
963
 
5
  Requires PHP: 5.3
6
  License: GPLv2 or later
7
  Tested up to: 5.4
8
+ Stable tag: 5.2.1
9
 
10
  Display a list of related posts on your site based on a powerful unique algorithm. Optionally, earn money by including sponsored content.
11
 
25
 
26
  **YARPP Algorithm Explained**
27
  -------------------------------------------
28
+
29
+ https://videopress.com/v/0n2TSzkb
30
 
31
  **Trusted since 2008**
32
  -------------------------------------------
271
  `
272
 
273
  == Changelog ==
274
+ = 5.2.1 (2020-07-20) =
275
+ * Enhancement: Don't recommend switching database engine unless necessary for fulltext indexes.
276
+
277
  = 5.2.0 (2020-07-20) =
278
  * Enhancement: Adds support for InnoDb fulltext search! One of our most requested features. Fulltext indexing is supported in MyISAM or InnoDB with MySQL 5.6.4 and higher.
279
  * Enhancement: Optimized database queries, resulting in ~2x speed improvement in some queries.
962
  * Initial upload
963
 
964
  == Upgrade Notice ==
965
+ = 5.2.1 =
966
  We update this plugin regularly so we can make it better for you. Update to the latest version for all of the available features and improvements. Thank you for using YARPP!
967
 
yarpp.php CHANGED
@@ -2,7 +2,7 @@
2
  /*
3
  Plugin Name: Yet Another Related Posts Plugin (YARPP)
4
  Description: Adds related posts to your site and in RSS feeds, based on a powerful, customizable algorithm.
5
- Version: 5.2.0
6
  Author: YARPP
7
  Author URI: https://yarpp.com/
8
  Plugin URI: https://yarpp.com/
@@ -23,7 +23,7 @@ if(!defined('WP_CONTENT_DIR')){
23
  define('WP_CONTENT_DIR', substr($tr,0,strrpos($tr,'/')));
24
  }
25
 
26
- define('YARPP_VERSION', '5.2.0');
27
 
28
  define('YARPP_DIR', dirname(__FILE__));
29
  define('YARPP_URL', plugins_url('',__FILE__));
2
  /*
3
  Plugin Name: Yet Another Related Posts Plugin (YARPP)
4
  Description: Adds related posts to your site and in RSS feeds, based on a powerful, customizable algorithm.
5
+ Version: 5.2.1
6
  Author: YARPP
7
  Author URI: https://yarpp.com/
8
  Plugin URI: https://yarpp.com/
23
  define('WP_CONTENT_DIR', substr($tr,0,strrpos($tr,'/')));
24
  }
25
 
26
+ define('YARPP_VERSION', '5.2.1');
27
 
28
  define('YARPP_DIR', dirname(__FILE__));
29
  define('YARPP_URL', plugins_url('',__FILE__));