Version Description
Download this release
Release Info
Developer | mitchoyoshitaka |
Plugin | Yet Another Related Posts Plugin (YARPP) |
Version | 3.1.4b4 |
Comparing to | |
See all releases |
Code changes from version 3.1.4b3 to 3.1.4b4
- keywords.php +1 -1
- magic.php +9 -12
- readme.txt +2 -0
- yarpp.php +2 -2
keywords.php
CHANGED
@@ -71,7 +71,7 @@ function yarpp_cache_keywords($ID) {
|
|
71 |
) ENGINE = MYISAM COMMENT = 'YARPP\'s keyword cache table'
|
72 |
*/
|
73 |
|
74 |
-
if (defined('DB_CHARSET')) {
|
75 |
$wpdb->query('set names '.DB_CHARSET);
|
76 |
}
|
77 |
|
71 |
) ENGINE = MYISAM COMMENT = 'YARPP\'s keyword cache table'
|
72 |
*/
|
73 |
|
74 |
+
if (defined('DB_CHARSET') && DB_CHARSET) {
|
75 |
$wpdb->query('set names '.DB_CHARSET);
|
76 |
}
|
77 |
|
magic.php
CHANGED
@@ -355,19 +355,16 @@ function yarpp_related_exist($type,$args,$reference_ID=false) {
|
|
355 |
if ($yarpp_time) // if we're already in a YARPP loop, stop now.
|
356 |
return false;
|
357 |
|
358 |
-
|
359 |
-
|
360 |
-
|
361 |
-
|
362 |
-
|
363 |
-
|
364 |
-
|
365 |
-
|
366 |
-
}
|
367 |
-
extract($optvals);
|
368 |
|
369 |
-
|
370 |
-
return $result > 0 ? true: false;
|
371 |
}
|
372 |
|
373 |
function yarpp_save_cache($post_ID,$force=true) {
|
355 |
if ($yarpp_time) // if we're already in a YARPP loop, stop now.
|
356 |
return false;
|
357 |
|
358 |
+
yarpp_cache_enforce($type,$reference_ID);
|
359 |
+
|
360 |
+
$yarpp_time = true; // get ready for YARPP TIME!
|
361 |
+
$related_query = new WP_Query();
|
362 |
+
$related_query->query(array('p'=>$reference_ID,'showposts'=>10000,'post_type'=>$type));
|
363 |
+
$return = $related_query->have_posts();
|
364 |
+
$yarpp_time = false; // YARPP time is over. :(
|
365 |
+
unset($related_query);
|
|
|
|
|
366 |
|
367 |
+
return $return;
|
|
|
368 |
}
|
369 |
|
370 |
function yarpp_save_cache($post_ID,$force=true) {
|
readme.txt
CHANGED
@@ -154,6 +154,8 @@ If you are a bilingual speaker of English and another language and an avid user
|
|
154 |
* Improved widget code
|
155 |
* Localization improvements - descriptions can now be localized
|
156 |
* [Compatibility with PageBar](http://wordpress.org/support/topic/346714) - thanks to Latz for the patch!
|
|
|
|
|
157 |
= 3.1.3 =
|
158 |
* Performance improvements:
|
159 |
* Turning off cache expiration, made possible by smarter caching system of 3.1 - should improve caching database performance over time.
|
154 |
* Improved widget code
|
155 |
* Localization improvements - descriptions can now be localized
|
156 |
* [Compatibility with PageBar](http://wordpress.org/support/topic/346714) - thanks to Latz for the patch!
|
157 |
+
* Bugfix: [`related_posts_exist` was giving incorrect values](http://wordpress.org/support/topic/362347)
|
158 |
+
* Bugfix: [SQL error for setups with blank DB_CHARSET](http://wordpress.org/support/topic/358757)
|
159 |
= 3.1.3 =
|
160 |
* Performance improvements:
|
161 |
* Turning off cache expiration, made possible by smarter caching system of 3.1 - should improve caching database performance over time.
|
yarpp.php
CHANGED
@@ -3,13 +3,13 @@
|
|
3 |
Plugin Name: Yet Another Related Posts Plugin
|
4 |
Plugin URI: http://mitcho.com/code/yarpp/
|
5 |
Description: Returns a list of related entries based on a unique algorithm for display on your blog and RSS feeds. A templating feature allows customization of the display.
|
6 |
-
Version: 3.1.
|
7 |
Author: mitcho (Michael Yoshitaka Erlewine)
|
8 |
Author URI: http://mitcho.com/
|
9 |
Donate link: https://www.paypal.com/cgi-bin/webscr?cmd=_donations&business=66G4DATK4999L&item_name=mitcho%2ecom%2fcode%3a%20donate%20to%20Michael%20Yoshitaka%20Erlewine&no_shipping=0&no_note=1&tax=0¤cy_code=USD&lc=US&charset=UTF%2d8
|
10 |
*/
|
11 |
|
12 |
-
define('YARPP_VERSION','3.1.
|
13 |
define('YARPP_DIR',dirname(__FILE__));
|
14 |
|
15 |
require_once(YARPP_DIR.'/includes.php');
|
3 |
Plugin Name: Yet Another Related Posts Plugin
|
4 |
Plugin URI: http://mitcho.com/code/yarpp/
|
5 |
Description: Returns a list of related entries based on a unique algorithm for display on your blog and RSS feeds. A templating feature allows customization of the display.
|
6 |
+
Version: 3.1.4b4
|
7 |
Author: mitcho (Michael Yoshitaka Erlewine)
|
8 |
Author URI: http://mitcho.com/
|
9 |
Donate link: https://www.paypal.com/cgi-bin/webscr?cmd=_donations&business=66G4DATK4999L&item_name=mitcho%2ecom%2fcode%3a%20donate%20to%20Michael%20Yoshitaka%20Erlewine&no_shipping=0&no_note=1&tax=0¤cy_code=USD&lc=US&charset=UTF%2d8
|
10 |
*/
|
11 |
|
12 |
+
define('YARPP_VERSION','3.1.4b4');
|
13 |
define('YARPP_DIR',dirname(__FILE__));
|
14 |
|
15 |
require_once(YARPP_DIR.'/includes.php');
|