0

I have an application that can launch Internet Explorer to a specific website. The problem is, if you include a question mark within the URL, it transforms it into %20; For example, if I tell it to go to: http://www.domain.com/default.aspx?id=572 when Internet Explorer opens, the webpage is changed to http://www.domain.com/default.aspx%20;id=572 and ASP.NET is unable to render the page when it looks like that.

I can't do anything to change the application, and as far as I can tell, there is no escape character.

Is there any other way I can pass a variable to ASP.NET other than with a QueryString from a third party application?

Pryach
  • 391
  • 2
  • 8
  • 18

1 Answers1

1

Try:

  • Put the parameter into the path:
    • http://www.domain.com/default.aspx/id=572, or
    • http://www.domain.com/default.aspx/572, or
  • (Ab)use matrix parameters: http://www.domain.com/default.aspx;id=572

Either way you'll need to change the ASP.NET service to extract those parameter types.

Community
  • 1
  • 1
Matt Ball
  • 354,903
  • 100
  • 647
  • 710
  • Thanks, I was actually able to put the parameter into the path, and then use Request.Url.AbsolutePath to find out what the id was. – Pryach Jan 10 '13 at 17:00