Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Westi on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How to detect if a folder is a virtual directory

Status
Not open for further replies.

jasonsalas

IS-IT--Management
Jun 20, 2001
480
GU
Does anyone have a clue how to write an ASP script to test if a certain folder is a virtual directory? Thanks!
 
use:

Path = Server.MapPath (Location)

The MapPath function can take any path(as long as it exists) and give you the actual HD location.

For example, if I wanted to find out where my root web folder was I would use:

Path = Server.MapPath ("/")

Path now equals C:\INETPUB\WWWROOT
 
Thanks...but my question was whether to test if a directory on a server is a virtual directory in IIS, or just a plain folder that got created. Got any ideas?
 
Exactly my point.. for instance.. you want to find out if


is a virtual or real folder.. use the map path..

if its real.. the path should be something like:

C:\INETPUB\
if its a virutal folder.. it would be something like:

D:\SOMESTUFF\CONTENT\FOLDER

This is rather a bad example for lack of a better way to visualize the concept.

Hope this cleared it up for you

GOrkem.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top