Forum Moderators: open

Message Too Old, No Replies

How to Use Server.MapPath

         

lindajames

3:17 pm on May 31, 2003 (gmt 0)

10+ Year Member



Hi,

I use the following code to check the physical path to my domain name:

<%= Server.MapPath("\")%>

But to do this i have to upload a file to the domain that i want to check. Can anyone tell me if this can be done remotely with any code?

Any suggestions would be very much appreciated.

Cheers
Linda

DaveN

12:31 pm on Jun 2, 2003 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



to find a virtual path you have to run the code on the server

Response.Write Request.ServerVariables("PATH_INFO")

Dave

Xoc

5:00 pm on Jun 2, 2003 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



You can't find this out without running code on the server because it is considered a possible security problem. If I know the physical layout of the server's hard disk, it becomes much easier to use another security flaw to do damage.