Skip to comments.
html question: image isn't displaying
Posted on 09/09/2009 5:32:49 PM PDT by rudy45
I am modifying html of a Word document that contains an image. Previously, the image location was an "absolute" location, e.g. src="C:/folder1/folder2/image001.jpg"
Now, however, I want the image location to be relative, not absolute. Specifically, I want to keep the html file and the image file in the same folder, regardless of name, and I want the html to be able to find the image file. I thought that this statement would do it:
src="image001.jpg"
However, when I view the html, I see no image, only that dreaded empty box. What am I doing wrong? Thanks.
TOPICS: Computers/Internet
KEYWORDS: html; internet
1
posted on
09/09/2009 5:32:49 PM PDT
by
rudy45
To: rudy45
Is the image in the same path as the doc?
2
posted on
09/09/2009 5:40:42 PM PDT
by
TheZMan
("I fear all we have done is to awaken a sleeping giant and fill him with a terrible resolve.")
To: rudy45
Is it on your computer or an image site like PhotoBucket?
3
posted on
09/09/2009 5:41:38 PM PDT
by
BunnySlippers
(I LOVE BULL MARKETS . . .)
To: rudy45
Move the image file to the same folder as the .html file. Then open your HTML editor and select the image and reinsert it from the same folder as the HTML file.
Good Hunting... from Varmint Al
To: rudy45
Just google “html path relative”
5
posted on
09/09/2009 5:42:54 PM PDT
by
Kirkwood
To: rudy45

With the image in the same directory as the Word .doc this should work.
6
posted on
09/09/2009 5:52:15 PM PDT
by
Boucheau
("Medicine is the keystone of the arch of socialism." - Vladimir Lenin)
To: Boucheau
Oops...
<img src="image.gif" />
With the image in the same directory as the source file this should work.
7
posted on
09/09/2009 5:56:25 PM PDT
by
Boucheau
("Medicine is the keystone of the arch of socialism." - Vladimir Lenin)
To: rudy45
make sure the image file and the html file are in the same directory. Then use <img src="your_file.jpg"> and it should most definitely display in any browser. Check for capital and lower case letters in your file name as File is not the same as file.
8
posted on
09/09/2009 6:00:00 PM PDT
by
zadox
(Government does not solve problems; it subsidizes them. Reagan)
To: rudy45
It should work that way — with no http: etc etc., the url is relative.
9
posted on
09/09/2009 6:00:25 PM PDT
by
freedumb2003
(Communism comes to America: 1/20/2009. Keep your powder dry, folks. Sic semper tyrannis)
To: rudy45
<img src="image001.jpg">
should work if the file in which it is contained is in the same folder as image001.jpg.
10
posted on
09/09/2009 6:01:21 PM PDT
by
cynwoody
To: cynwoody; zadox; freedumb2003; Kirkwood; Boucheau; TheZMan; Varmint Al; BunnySlippers
thanks for your help. I resolved the issue. Somehow, Windows Explorer, or Firefox or something else was renaming the file to image001x.jpg. So of course the html wasn’t finding the file. I renamed it back, and everything is fine.
Thanks for your help.
11
posted on
09/10/2009 3:27:20 AM PDT
by
rudy45
Disclaimer:
Opinions posted on Free Republic are those of the individual
posters and do not necessarily represent the opinion of Free Republic or its
management. All materials posted herein are protected by copyright law and the
exemption for fair use of copyrighted works.
FreeRepublic.com is powered by software copyright 2000-2008 John Robinson