WordPress.org

Make WordPress Core

Changeset 16526


Ignore:
Timestamp:
11/21/2010 04:33:05 PM (9 years ago)
Author:
scribu
Message:

Move s/ /+ out of WP_Query, so that 'category_name=Some Category' works again. See #12891

Location:
trunk/wp-includes
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-includes/class-wp.php

    r16101 r16526  
    272272            }
    273273        }
     274
     275        // Convert urldecoded spaces back into +
     276        foreach ( $GLOBALS['wp_taxonomies'] as $taxonomy => $t )
     277            if ( $t->query_var && isset( $this->query_vars[$t->query_var] ) )
     278                $this->query_vars[$t->query_var] = str_replace( ' ', '+', $this->query_vars[$t->query_var] );
    274279
    275280        // Limit publicly queried post_types to those that are publicly_queryable
  • trunk/wp-includes/query.php

    r16515 r16526  
    15081508                }
    15091509
    1510                 $term = str_replace( ' ', '+', $q[$t->query_var] );
     1510                $term = $q[$t->query_var];
    15111511
    15121512                if ( strpos($term, '+') !== false ) {
Note: See TracChangeset for help on using the changeset viewer.