c# - How can I modify or handle URL special characters in MVC? -
i have mvc web application. url particular area coming in as:
http://localhost/general/bpa%3fapplication%3dtrf%23/generalinputs
this causes "the resource cannot found." error. however, if change url
http://localhost/general/bpa?application=trf#/generalinputs
then works. can see using route debugging tricks controller in first case is: "bpa?application=trf#", whereas second 1 is: "bpa", correct. how can account or substitute encoded characters?
you're going want use on url:
string fixedurl = system.uri.unescapedatastring(yoururlhere);
hope works out you!
Comments
Post a Comment