WordPress removes spaces in URL on pagination

I’m having a problem with wordpress rewriting my URLs, basically I have a regular search form with method set as GET, when I submit it the URL looks like this at first:

http://mysite.com/news/?type=My+Variable

Read More

WordPress adds the + symbol to separate the string and the results show fine, but when I click on the previous posts link the URL changes to:

http://mysite.com/news/page/2/?type=MyVariable

Since the type parameter is now MyVariable it shows me no results, it doesn’t matter if I type the + sign directly in the URL, when I press ENTER it just gets removed.

It seems to be related to how wordpress handles canonical URLs but I’m not sure about it, can anyone help me?

Thanks in advance.

Related posts

Leave a Reply

1 comment