Changeset 350763
- Timestamp:
- 02/25/2011 02:09:35 AM (15 years ago)
- Location:
- elevate-parent-category-template/trunk
- Files:
-
- 2 edited
-
elevate-parent-category-template.php (modified) (2 diffs)
-
readme.txt (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
elevate-parent-category-template/trunk/elevate-parent-category-template.php
r350756 r350763 3 3 Plugin Name: Elevate Parent Category Template 4 4 Description: Elevates parent category template to top of Wordpress Loop. 5 Version: 1.0 5 Version: 1.0.3 6 6 Author: Jeremy Foo 7 7 Author URI: http://thirdly.org/ … … 86 86 // fix from marty@halfempty to deal with custom template. 87 87 if (!file_exists(STYLESHEETPATH . '/category-' . $category->slug . '.php')) { 88 //fix for WP 3.1 89 $parent = get_category($parent); 90 $wp_query->queried_object->slug = $parent->slug; 88 if (version_compare($wp_version, '3.1', '>=')) { 89 //fix for WP 3.1 90 $parent = get_category($parent); 91 $wp_query->queried_object->slug = $parent->slug; 92 93 } else { 94 $wp_query->query_vars['cat'] = $parent; 95 96 } 97 91 98 } 92 99 } -
elevate-parent-category-template/trunk/readme.txt
r350756 r350763 5 5 Tested up to: 3.1 6 6 Requires at least: 2.5 7 Stable tag: 1.0. 27 Stable tag: 1.0.3 8 8 9 9 Elevates parent category template to top of WordPress Loop.
Note: See TracChangeset
for help on using the changeset viewer.