theclassic
asked on
Point xmldoc.load to a root file when it is being called be a virtual directory tag within a subfolder
Hi, I have an IIS server with a universal web.config for connection strings. i have older classic asp files I wrote a script for to parse the web.config file. I want both the connection.asp and the web.config to sit on the root level.
I successfully connect to the connection .asp at the root level using this tag within the classic asp pages <!--#include virtual="/ClientConnection .asp"-->
But when it reads this file, it will only connect to a web.config file within the folder, not at the root - this is the code that loads the web.config
xmlDoc.Load(Server.Mappath ("web.conf ig"))
Can I make this to force it to point to a root file?
I successfully connect to the connection .asp at the root level using this tag within the classic asp pages <!--#include virtual="/ClientConnection
But when it reads this file, it will only connect to a web.config file within the folder, not at the root - this is the code that loads the web.config
xmlDoc.Load(Server.Mappath
Can I make this to force it to point to a root file?
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Server.Mappath means current folder.. As long as you left everything default in IIS, then the application physical path will be the root of the website.