开发者

From within an ISAPI filter, how to determine the virtual path for an IIS application?

Is there a way, inside an ISAPI Filter, to determine the virtual path for the IIS application or virtual directory?

It's basically the same question as IIS Root Path vs Path of virtual directory, but rather than 开发者_如何转开发within an ASP.NET application, I want this from within an ISAPI filter.

Does the value of the server variable APPL_MD_PATH always ends with the actual virtual path of an application? Is it true that the format of APPL_MD_PATH is always

/LM/W3SVC/<sitenumber>/ROOT/<Website_vdir>

?


I don't know for sure, but I am guessing that the format for APPL_MD_PATH is always as above, so one can just get the tail segment of that server variable to get the virtual path.

Need to special case the root vdir.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜