| 9:06 pm on May 4, 2007 (gmt 0)|
I've been looking for the answer to this for a while now, and I am not sure that it is achievable under IIS.
Unless I am totaly wrong and have not found the answer.
The trick you could do is set a different document as defalt page for root directory, and 301 index to it, but this is untill someone links to that new document, so no purpose there.
| 10:56 pm on May 4, 2007 (gmt 0)|
Try Request.ServerVariables("SCRIPT_NAME"), this should give you '/index.asp' and then you can 301 '/'.
| 5:20 am on May 7, 2007 (gmt 0)|
That will put you into an infinite redirect.
| 4:15 pm on May 7, 2007 (gmt 0)|
carguy84 is right.
I tested Request.ServerVariables("SCRIPT_NAME")
It produces exactly the same response whether I type index.asp in the URL or not.
| 4:27 pm on May 7, 2007 (gmt 0)|
|Anyone any ideas how I can flick www.mydomain.com/index.asp to www.mydomain.com? |
You can also 301 redirect mydomain.com to www.mydomain.com, plus many other neat things.
| 9:34 pm on May 25, 2007 (gmt 0)|
I posted a similar answer to another question earlier this evening. This assumes you are using VB/C#:-
You can do a lot in the Application_BeginRequest event in Global.asax.vb. You intercept specific pages using:-
and then use:-
It is what Isapi filters do but within .NET itself.
| 9:31 pm on May 26, 2007 (gmt 0)|
Numpty, check my response on this thread: