Changeset 262 for trunk/xpressme_integration_kit/wp-content/themes/xpress_default/blocks/popular_posts_block_theme.php
- Timestamp:
- Jun 8, 2009, 5:55:59 PM (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/xpressme_integration_kit/wp-content/themes/xpress_default/blocks/popular_posts_block_theme.php
r158 r262 44 44 45 45 $select = "SELECT $view_tb.post_views, $post_tb.ID, $post_tb.post_title, $post_tb.post_date"; 46 46 if ($wp_db_version >= 6124){ 47 47 $from = " FROM ((("; 48 48 $from .= " $post_tb LEFT JOIN $view_tb ON $post_tb.ID = $view_tb.post_id)"; … … 66 66 $where .= " AND ($term_taxonomy.term_id IN ($tag_id_list))"; 67 67 } 68 } else { 69 $from = " FROM (("; 70 $from .= " $post_tb LEFT JOIN $view_tb ON $post_tb.ID = $view_tb.post_id)"; 71 $from .= " LEFT JOIN $post2cat_tb ON $post_tb.ID = $post2cat_tb.post_id)"; 72 $from .= " INNER JOIN $user_tb ON $post_tb.post_author = $user_tb.ID"; 73 74 $where = " WHERE ($post_tb.post_status = 'publish') AND (UNIX_TIMESTAMP($post_tb.post_date) <= UNIX_TIMESTAMP())" ; 75 76 if ($cat_select) { 77 $where .= " AND ($post2cat_tb.category_id IN ($cat_id))"; 78 } 79 } 68 80 69 81 … … 106 118 ob_end_clean(); 107 119 108 ob_start(); 109 the_tags(__('Tags:', 'kubrick') . ' ',' • ',''); 110 $tags = ob_get_contents(); 111 ob_end_clean(); 120 if (function_exists('the_tags')){ 121 ob_start(); 122 the_tags(__('Tags:', 'xpress') . ' ',' • ',''); 123 $tags = ob_get_contents(); 124 ob_end_clean(); 125 } else { 126 $tags = ''; 127 } 112 128 113 129 ob_start(); … … 115 131 $post_modified_date = ob_get_contents(); 116 132 ob_end_clean(); 117 133 118 134 ob_start(); 119 135 the_modified_date($time_format);
Note: See TracChangeset
for help on using the changeset viewer.