Title: wordpress 2.9.2 query string question
Last modified: August 19, 2016

---

# wordpress 2.9.2 query string question

 *  [shiroamada](https://wordpress.org/support/users/shiroamada/)
 * (@shiroamada)
 * [15 years, 9 months ago](https://wordpress.org/support/topic/wordpress-292-query-string-question/)
 * I just find out something with wordpress
 * This is the query string I build,
 * > [http://localhost/wp/?test%5B%5D=1&test%5B%5D=2](http://localhost/wp/?test%5B%5D=1&test%5B%5D=2)
 * `print_r($_GET);`
 * return array.
 * however, when I added ?& together, like below
 * > [http://localhost/wp/?&test%5B%5D=1&test%5B%5D=2](http://localhost/wp/?&test%5B%5D=1&test%5B%5D=2)
 * wordpress will redirect to
 * > [http://localhost/wp/?test=1&test=2](http://localhost/wp/?test=1&test=2)
 * my test array disappear, may I know why will this happen, and what is the rational
   behind.
 * Normal PHP should have this problem, I not sure why wordpress implement this.
   How can remove this trick?
 * Thank you so much.

Viewing 1 replies (of 1 total)

 *  Thread Starter [shiroamada](https://wordpress.org/support/users/shiroamada/)
 * (@shiroamada)
 * [15 years, 9 months ago](https://wordpress.org/support/topic/wordpress-292-query-string-question/#post-1547464)
 * I did some edit, no sure it is safe or not, please comment on this solution.
   
   wp-includes\canonical.php original:
 * > // Note that you can use the “redirect_canonical” filter to cancel a canonical
   > redirect for whatever reason by returning FALSE
   >  $redirect_url = apply_filters(‘
   > redirect_canonical’, $redirect_url, $requested_url);
   >  if ( !$redirect_url || $redirect_url == $requested_url ) // yes, again — in
   > case the filter aborted the request
   >  return false;
 * line 293 I added
 * >  list($base_url, $query_string) = explode(‘?’,$requested_url);
   >  $position =
   > strpos($query_string, ‘&’); if($redirect_url != $requested_url) { if($position
   > == 0) { return false; } }
 * After I did the edit, I able to passing with ?& together without any problem.

Viewing 1 replies (of 1 total)

The topic ‘wordpress 2.9.2 query string question’ is closed to new replies.

## Tags

 * [Query String](https://wordpress.org/support/topic-tag/query-string/)

 * In: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
 * 1 reply
 * 1 participant
 * Last reply from: [shiroamada](https://wordpress.org/support/users/shiroamada/)
 * Last activity: [15 years, 9 months ago](https://wordpress.org/support/topic/wordpress-292-query-string-question/#post-1547464)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
