regex question for .net query string

Topics: Developer Forum
Jul 15, 2010 at 7:42 PM

i want to redirect (sample url) using the RedirectRule command

http://www.test.com?page.aspx?id=20&page=23&kt=poster

to

http://www.test.com?page.aspx?id=33&page=44

i assume that the new page can be written as is

how do you code the regex request page?

RedirectRule ?  http://www.test.com?page.aspx?id=33&page=44 [R=301]

i have searched around the regex pages -but i am having trouble making this work

 

thanks in advance

 

Jul 16, 2010 at 2:44 PM
i was able to get this far RedirectRule ^/(page\.aspx)(.*)$ http://www.test.com/page.aspx?id=33&page=44 which will redirect all urls starting with page to the new page but i can't figure how to add the rest of the query string id=20&page=23&kt=poster any help would be appreciated