Changeset 4721
- Timestamp:
- 01/11/2007 04:30:44 AM (18 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-includes/link-template.php
r4644 r4721 297 297 } 298 298 299 return @$wpdb->get_row("SELECT ID, post_title FROM $wpdb->posts $join WHERE post_date < '$current_post_date' AND post_type = 'post' AND post_status = 'publish' $posts_in_ex_cats_sql ORDER BY post_date DESC LIMIT 1"); 299 $join = apply_filters( 'get_previous_post_join', $join, $in_same_cat, $excluded_categories ); 300 $where = apply_filters( 'get_previous_post_where', "WHERE post_date < '$current_post_date' AND post_type = 'post' AND post_status = 'publish' $posts_in_ex_cats_sql", $in_same_cat, $excluded_categories ); 301 $sort = apply_filters( 'get_previous_post_sort', 'ORDER BY post_date DESC LIMIT 1' ); 302 303 return @$wpdb->get_row("SELECT ID, post_title FROM $wpdb->posts $join $where $sort"); 300 304 } 301 305 … … 330 334 } 331 335 332 return @$wpdb->get_row("SELECT ID,post_title FROM $wpdb->posts $join WHERE post_date > '$current_post_date' AND post_type = 'post' AND post_status = 'publish' $posts_in_ex_cats_sql AND ID != $post->ID ORDER BY post_date ASC LIMIT 1"); 336 $join = apply_filters( 'get_next_post_join', $join, $in_same_cat, $excluded_categories ); 337 $where = apply_filters( 'get_next_post_where', "WHERE post_date > '$current_post_date' AND post_type = 'post' AND post_status = 'publish' $posts_in_ex_cats_sql AND ID != $post->ID", $in_same_cat, $excluded_categories ); 338 $sort = apply_filters( 'get_next_post_sort', 'ORDER BY post_date ASC LIMIT 1' ); 339 340 return @$wpdb->get_row("SELECT ID, post_title FROM $wpdb->posts $join $where $sort"); 333 341 } 334 342
Note: See TracChangeset
for help on using the changeset viewer.