summaryrefslogtreecommitdiffstats
path: root/wp-includes/category.php
diff options
context:
space:
mode:
authordonncha <donncha@7be80a69-a1ef-0310-a953-fb0f7c49ff36>2008-04-04 16:44:15 +0000
committerdonncha <donncha@7be80a69-a1ef-0310-a953-fb0f7c49ff36>2008-04-04 16:44:15 +0000
commit7740e89de3e1bc0cc636120e3ca8ab9e97e4d3cc (patch)
treec6fd23b598f3994eddb18cb1c0f2e8d95ff054fa /wp-includes/category.php
parentf650f48c048bfbbb2ae702b6425d87e39358d748 (diff)
downloadwordpress-mu-7740e89de3e1bc0cc636120e3ca8ab9e97e4d3cc.tar.gz
wordpress-mu-7740e89de3e1bc0cc636120e3ca8ab9e97e4d3cc.tar.xz
wordpress-mu-7740e89de3e1bc0cc636120e3ca8ab9e97e4d3cc.zip
Merged with WordPress 2.5, unstable, only for testing
git-svn-id: http://svn.automattic.com/wordpress-mu/trunk@1218 7be80a69-a1ef-0310-a953-fb0f7c49ff36
Diffstat (limited to 'wp-includes/category.php')
-rw-r--r--wp-includes/category.php16
1 files changed, 0 insertions, 16 deletions
diff --git a/wp-includes/category.php b/wp-includes/category.php
index 71e5be8..193390d 100644
--- a/wp-includes/category.php
+++ b/wp-includes/category.php
@@ -1,8 +1,6 @@
<?php
function get_all_category_ids() {
- global $wpdb;
-
if ( ! $cat_ids = wp_cache_get('all_category_ids', 'category') ) {
$cat_ids = get_terms('category', 'fields=ids&get=all');
wp_cache_add('all_category_ids', $cat_ids, 'category');
@@ -39,7 +37,6 @@ function &get_category($category, $output = OBJECT, $filter = 'raw') {
}
function get_category_by_path($category_path, $full_match = true, $output = OBJECT) {
- global $wpdb;
$category_path = rawurlencode(urldecode($category_path));
$category_path = str_replace('%2F', '/', $category_path);
$category_path = str_replace('%20', ' ', $category_path);
@@ -86,8 +83,6 @@ function get_category_by_slug( $slug ) {
// Get the ID of a category from its name
function get_cat_ID($cat_name='General') {
- global $wpdb;
-
$cat = get_term_by('name', $cat_name, 'category');
if ($cat)
return $cat->term_id;
@@ -132,22 +127,11 @@ function sanitize_category_field($field, $value, $cat_id, $context) {
// Tags
function &get_tags($args = '') {
- global $wpdb, $category_links;
-
- $key = md5( serialize( $args ) );
- if ( $cache = wp_cache_get( 'get_tags', 'category' ) )
- if ( isset( $cache[ $key ] ) )
- return apply_filters('get_tags', $cache[$key], $args);
-
-
$tags = get_terms('post_tag', $args);
if ( empty($tags) )
return array();
- $cache[ $key ] = $tags;
- wp_cache_set( 'get_tags', $cache, 'category' );
-
$tags = apply_filters('get_tags', $tags, $args);
return $tags;
}