I have a C# website which works fine in IIS6 & IIS7 on a company intranet but am now attempting to install the same website on a Windows XP box with IIS5 for a different part of the company intranet. The website content is fine but the css and menus are all broken, as some of the relative paths can't be found.
I am using some notation like this: <img src="Images/a.gif"
which works fine, and some like this: MasterPageFile="~/App_MasterPages/Default.master"
which also works fine, but the stuff like this: @import "/App_Themes/Default.css"
and this: src="../App_Scripts/stringformat.js"
is no good. In the code-behind Request.ApplicationPath
is also missing the "/" off the end.
I tried unticking the "Enable Parent Path" in IIS and did an iisreset but it made no difference. I also tried installing IIS Developer Express, but that was confusing and sucked too much. I don't want to have to go through the whole application and change every relative path just to support IIS5 format, but is that my only option? (apart from upgrading Windows)