spaces in url redirects to default website, how can I change the root?

If the selected value has a space, it get redirected to default website.

This is the page code.

Response.Redirect("~/tsAdmin/Marketing/OffersEdit.aspx?type=" + Server.UrlEncode(OfferTypeDropDownList.SelectedValue))

This will work

localhost:8011/tsAdmin/Marketing/OffersEdit.aspx?type=Shipping

But this will not work

localhost:8011/tsadmin/marketing/offersedit.aspx?type=buy%20x%20get%20y%20by%20category

it get redirected to localhost/bvadmin/marketing/offersedit.aspx?type=buy%20x%20get%20y%20by%20category

I'm assuming this is an IIS settings or in web.config.

Answers


This was a setting in IIS. Needed to add .aspx pages as a recognized page.

Still not sure why it busted only when the param had a space, but its working now.


Need Your Help

Exclude foreign keys from sql query

sql postgresql

I've got some sql joining a few tables together

Eclipse unable to explode jar

eclipse jar

I am using Eclipse platform for Java development. There are pre-existing jar files which are being referenced in code (added in build path). It is very surprising for me that some of the jars are not