Forum Moderators: phranque
Index.shtml is in the public_html directory of my server. If I put a server side include in index.shtml that asks for a txt file from /public_html/ads, it will look like this....
<!--#include file="./ads/728-468x90-60.txt"-->
And it works great. Now........
I have another directory with a file in it located at /public_html/windows2003/start.htm. I want to put an SSI in start.htm and it will look like this....or so I thought...
<!--#include file="../ads/728-468x90-60.txt"-->
<!--#include file="/public_html/ads/728-468x90-60.txt"-->
<!--#include file="../../ads/728-468x90-60.txt"-->
<!--#include file="./ads/728-468x90-60.txt"-->
<!--#include file="/./ads/728-468x90-60.txt"-->
But none of these paths enable me to get the same file from /public_html/ads/. Plus I have tried many more. Does anyone know how to access this file from this location? Or know how to access directories with SSIs? Paths, to me, are strange with SSIs.
It looks like using virtual (below) instead of file (above) will do the trick. I did a search on the forums and found the solution. I did a search before I posted but wasn't patient enough. The code below works.
<!--#include virtual="/ads/728-468x90-60.txt"-->