Take the 2-minute tour ×

I have the following URL : "http:/server/Search/term/5" where term is the seached term and 5 the page

On that page, I have filters that filter the results.

My problem is I have less than 5 pages of results, I end up on empty page. I would like to "redirect" or "edit" the url to "http:/server/Search/term"

I use a CheckBoxList with AutoPostBack true.

I also tried with a Button and setting the PostBackUrl to my url but I'm loosing all the checked filters.

I'm using IRouteHandler.

How would I be able to do that ?

share|improve this question
You could use a query string instead; then it's just a number, not part of the path, thus more easily ignored. You could also use Response.Redirect(). –  KeithS Nov 30 '12 at 16:36
My suggestion,on page load, check for the availability of content and redirect the user to main url if id content is empty –  CodeSpread Nov 30 '12 at 16:48

1 Answer 1

up vote 0 down vote accepted

I've finally put the page parameter in the querystring.

The Button with a PostBackUrl then works like a charm.

Thanks KeithS !

share|improve this answer

Your Answer


