doc_root outside IIS root?
Posted on 2005-03-06
I have a website hosted on Apache; I develop, however, using IIS IIS 5.1 on Windows XP.
I want a generic template such that I can use both of (for example):
* <link rel="stylesheet" type="text/css" href="/stylesheets/public.css" />
(where /home/mysite/public_html is the root to my website on the live server).
This is fine on the live box, but I cannot replicate it locally - let the physical path to the local root directory be c:\mywebsite\home\mysite\public_html - if I set the IIS root directory to be c:\mywebsite, the PHP include works fine but the stylesheet link is wrong; if I set the IIS root directory to be c:\mywebsite\home\mysite\public_html the stylesheet link works fine but the PHP include breaks.
I thought about setting the doc_root in php.ini to c:\mywebsite and the IIS root directory to c:\mywebsite\home\mysite\public_html, but then IIS returns a 404 error whenever it tries to interpret a PHP page.
Any suggestions? - I don't particularly want to install Apache or start setting include paths every time I use PHP...
Many thanks in advance,