Version Description
Download this release
Release Info
Developer | mitchoyoshitaka |
Plugin | Yet Another Related Posts Plugin (YARPP) |
Version | 3.0.8b1 |
Comparing to | |
See all releases |
Code changes from version 3.0.7 to 3.0.8b1
- includes.php +9 -11
- magic.php +9 -1
- readme.txt +4 -0
- yarpp.php +4 -1
includes.php
CHANGED
@@ -126,8 +126,8 @@ function yarpp_activate() {
|
|
126 |
return 0;
|
127 |
}
|
128 |
}
|
129 |
-
add_option('yarpp_version',
|
130 |
-
update_option('yarpp_version',
|
131 |
return 1;
|
132 |
}
|
133 |
|
@@ -178,8 +178,8 @@ function yarpp_upgrade_check($inuse = false) {
|
|
178 |
$wpdb->query("ALTER TABLE $wpdb->posts ADD FULLTEXT `yarpp_content` ( `post_content`)"); update_option('yarpp_version','2.03');
|
179 |
}
|
180 |
|
181 |
-
if (eregi_replace('[a-z].*$','',get_option('yarpp_version')) <
|
182 |
-
update_option('yarpp_version',
|
183 |
|
184 |
//if (!$inuse)
|
185 |
// echo '<div id="message" class="updated fade" style="background-color: rgb(207, 235, 247);">'.__('<h3>An important message from YARPP:</h3><p>Thank you for upgrading to YARPP 2. YARPP 2.0 adds the much requested ability to limit related entry results by certain tags or categories. 2.0 also brings more fine tuned control of the magic algorithm, letting you specify how the algorithm should consider or not consider entry content, titles, tags, and categories. Make sure to adjust the new settings to your liking and perhaps readjust your threshold.</p><p>For more information, check out the <a href="http://mitcho.com/code/yarpp/">YARPP documentation</a>. (This message will not be displayed again.)</p>','yarpp').'</div>';
|
@@ -220,13 +220,11 @@ function widget_yarpp_init() {
|
|
220 |
extract($args);
|
221 |
global $wpdb, $post;
|
222 |
if (is_single() && have_posts()) {
|
223 |
-
|
224 |
-
|
225 |
-
|
226 |
-
|
227 |
-
|
228 |
-
echo $after_widget;
|
229 |
-
}
|
230 |
}
|
231 |
}
|
232 |
register_sidebar_widget(__('YARPP','yarpp'), 'widget_yarpp');
|
126 |
return 0;
|
127 |
}
|
128 |
}
|
129 |
+
add_option('yarpp_version',YARPP_VERSION);
|
130 |
+
update_option('yarpp_version',YARPP_VERSION);
|
131 |
return 1;
|
132 |
}
|
133 |
|
178 |
$wpdb->query("ALTER TABLE $wpdb->posts ADD FULLTEXT `yarpp_content` ( `post_content`)"); update_option('yarpp_version','2.03');
|
179 |
}
|
180 |
|
181 |
+
if (eregi_replace('[a-z].*$','',get_option('yarpp_version')) < YARPP_NUMERICAL_VERSION or get_option('yarpp_version') != YARPP_VERSION) {
|
182 |
+
update_option('yarpp_version',YARPP_VERSION);
|
183 |
|
184 |
//if (!$inuse)
|
185 |
// echo '<div id="message" class="updated fade" style="background-color: rgb(207, 235, 247);">'.__('<h3>An important message from YARPP:</h3><p>Thank you for upgrading to YARPP 2. YARPP 2.0 adds the much requested ability to limit related entry results by certain tags or categories. 2.0 also brings more fine tuned control of the magic algorithm, letting you specify how the algorithm should consider or not consider entry content, titles, tags, and categories. Make sure to adjust the new settings to your liking and perhaps readjust your threshold.</p><p>For more information, check out the <a href="http://mitcho.com/code/yarpp/">YARPP documentation</a>. (This message will not be displayed again.)</p>','yarpp').'</div>';
|
220 |
extract($args);
|
221 |
global $wpdb, $post;
|
222 |
if (is_single() && have_posts()) {
|
223 |
+
the_post();
|
224 |
+
echo $before_widget;
|
225 |
+
echo $before_title . __('Related Posts','yarpp') . $after_title;
|
226 |
+
echo yarpp_related(array('post'),array());
|
227 |
+
echo $after_widget;
|
|
|
|
|
228 |
}
|
229 |
}
|
230 |
register_sidebar_widget(__('YARPP','yarpp'), 'widget_yarpp');
|
magic.php
CHANGED
@@ -285,6 +285,10 @@ function yarpp_related($type,$args,$echo = true,$reference_ID=false,$domain = 'w
|
|
285 |
$current_page = $page;
|
286 |
$current_pages = $pages;
|
287 |
$current_authordata = $authordata;
|
|
|
|
|
|
|
|
|
288 |
|
289 |
$related_query = new WP_Query();
|
290 |
$orders = split(' ',$order);
|
@@ -317,7 +321,11 @@ function yarpp_related($type,$args,$echo = true,$reference_ID=false,$domain = 'w
|
|
317 |
$pages = null; $pages = $current_pages; unset($current_pages);
|
318 |
$id = $current_id; unset($current_id);
|
319 |
$page = $current_page; unset($current_page);
|
320 |
-
|
|
|
|
|
|
|
|
|
321 |
if ($promote_yarpp and $domain != 'metabox')
|
322 |
$output .= "\n<p>".__("Related posts brought to you by <a href='http://mitcho.com/code/yarpp/'>Yet Another Related Posts Plugin</a>.",'yarpp')."</p>";
|
323 |
|
285 |
$current_page = $page;
|
286 |
$current_pages = $pages;
|
287 |
$current_authordata = $authordata;
|
288 |
+
$current_numpages = $numpages;
|
289 |
+
$current_multipage = $multipage;
|
290 |
+
$current_more = $more;
|
291 |
+
$current_pagenow = $pagenow;
|
292 |
|
293 |
$related_query = new WP_Query();
|
294 |
$orders = split(' ',$order);
|
321 |
$pages = null; $pages = $current_pages; unset($current_pages);
|
322 |
$id = $current_id; unset($current_id);
|
323 |
$page = $current_page; unset($current_page);
|
324 |
+
$numpages = null; $numpages = $current_numpages; unset($current_numpages);
|
325 |
+
$multipage = null; $multipage = $current_multipage; unset($current_multipage);
|
326 |
+
$more = null; $more = $current_more; unset($current_more);
|
327 |
+
$pagenow = null; $pagenow = $current_pagenow; unset($current_pagenow);
|
328 |
+
|
329 |
if ($promote_yarpp and $domain != 'metabox')
|
330 |
$output .= "\n<p>".__("Related posts brought to you by <a href='http://mitcho.com/code/yarpp/'>Yet Another Related Posts Plugin</a>.",'yarpp')."</p>";
|
331 |
|
readme.txt
CHANGED
@@ -263,3 +263,7 @@ If you are a bilingual speaker of English and another language and an avid user
|
|
263 |
* Updated Italian
|
264 |
* Added Belarussian by [Fat Cow](http://www.fatcow.com)
|
265 |
* Confirmed compatibility with 2.8.1
|
|
|
|
|
|
|
|
263 |
* Updated Italian
|
264 |
* Added Belarussian by [Fat Cow](http://www.fatcow.com)
|
265 |
* Confirmed compatibility with 2.8.1
|
266 |
+
* 3.0.8
|
267 |
+
* Bugfix: [a pagination issue](http://wordpress.org/support/topic/267350)
|
268 |
+
* Bugfix: a quick bugfix for widgets, thanks to Chris Northwood
|
269 |
+
* Added Lithuanian localization
|
yarpp.php
CHANGED
@@ -3,12 +3,15 @@
|
|
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.0.
|
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 |
require_once('includes.php');
|
13 |
require_once('related-functions.php');
|
14 |
require_once('template-functions.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.0.8b1
|
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_NUMERICAL_VERSION','3.08');
|
13 |
+
define('YARPP_NUMERICAL_VERSION','3.08b1');
|
14 |
+
|
15 |
require_once('includes.php');
|
16 |
require_once('related-functions.php');
|
17 |
require_once('template-functions.php');
|