toyman61
asked on
How-to reference an image in another folder?
I have an Apache-server with images in a folder called "Images" near the root of the webserver (www/images).
Now I have folder tree with folders containing header-files with references to images in the images folder.
(An example: www/Info/Documents/Bills. In the 'Info'-folder I have a file called "header.htm" which has a reference to
an image called "companylogo.gif". The URI created by Word 2003 is <a href="../images/companylog o.gif" and that works fine).
But when I try to reference the same image-file from the 'Bills'-folder with URI <a href="../../../images/comp anylogo.gi f" I get an 404 error when I try to show that image. Why ?
Now I have folder tree with folders containing header-files with references to images in the images folder.
(An example: www/Info/Documents/Bills. In the 'Info'-folder I have a file called "header.htm" which has a reference to
an image called "companylogo.gif". The URI created by Word 2003 is <a href="../images/companylog
But when I try to reference the same image-file from the 'Bills'-folder with URI <a href="../../../images/comp
From /Info/Documents/Bills/ via ../../../images/companylog o.gif to /images/...... looks correct.
And which resource did your browser request? You can monitor the HTTP headers with a firefox extension: https://addons.mozilla.org/de/firefox/addon/3829
You should find a menu entry in your tools menu after installing the extension. Open it and request your page after you cleared your cache. Does your browser request
GET /images/companylogo.gif ?
And which resource did your browser request? You can monitor the HTTP headers with a firefox extension: https://addons.mozilla.org/de/firefox/addon/3829
You should find a menu entry in your tools menu after installing the extension. Open it and request your page after you cleared your cache. Does your browser request
GET /images/companylogo.gif ?
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Your path does not look correct.
../images/companylogo.gif is the first folder then you have another folder called images.
should be /../images/companylogo.gif