WD2001: Images Lost After Using Save As Web Page Command (272830)
The information in this article applies to:
- Microsoft Word 2001 for Macintosh
- Microsoft Word 98 Macintosh Edition
This article was previously published under Q272830 SYMPTOMS
When you open a Web page using the Open Web Page command on the File menu in Microsoft Word 2001 for Mac or Microsoft Word 98 Macintosh Edition, and then you save the Web page using the Save As Web Page command on the File menu, when you open the saved document, the pictures may be missing.
CAUSE
This behavior can occur if the link from the Web page to the pictures uses a root-relative link instead of an absolute link or a document-relative link.
For example, if you have a Hypertext Markup Language (HTML) page, mypage.htm, that is linked to myimage.jpg, and the page is located at the following address
http://www.mysite.com/wwwroot/articles/2000/mypage.htm
and the picture is located at the following address
http://www.mysite.com/wwwroot/images/myimage.jpg
there are three ways that you can link to the image from mypage.htm:
- Absolute link: <img src="http://www.mysite/com/wwwroot/images/myimage.jpg">
- Document-relative link: <img src="../../images/myimage.jpg"> (the link to the image refers two folders up the directory path)
- Root-relative link: <img src="/wwwroot/images/myimage.jpg"> (the link to the image starts at the first folder that comes after the domain)
When the document is saved off the Internet, Word changes document-relative links to absolute links. Root-relative links are not properly changed to absolute links, and those links are broken.
WORKAROUND
To work around this issue, change the broken root-relative links to absolute links; to do so, follow these steps:
- Open the file with the broken links, and then click OK in the Convert File dialog box.
- Click HTML Source on the View menu.
- On the Edit menu, click Replace.
- In the Find what box, type src="%2F.
- In the Replace with box, type src="http://top level (where top level is the path to the relative root), and then click Replace All.
- In the Find what box, type %2520.
- In the Replace with box, type %20, and then click Replace All.
- In the Find what box, type %2F.
- In the Replace with box, type /, and then click Replace All.
- Close the Find and Replace dialog box, and then close and save the document.
- When the following message appears
This document contains formatting that cannot be saved in text format. Do you want to save changes to mypage.htm?.
click Save. - When the following message appears
This document may contain formatting which will be lost upon conversion to Text Only format. To preserve the initial document, click No to exit this dialog, then save the document in Word format before converting. Continue with save?
click Yes.NOTE: These two alerts appear only when you first save the document.
STATUSMicrosoft has confirmed that this is a problem in the Microsoft products that are listed at the beginning of this article.
Modification Type: | Major | Last Reviewed: | 10/14/2002 |
---|
Keywords: | kbbug KB272830 |
---|
|