Microsoft KB Archive/170720: Difference between revisions

From BetaArchive Wiki
m (Text replacement - ">" to ">")
m (Text replacement - """ to """)
 
Line 12: Line 12:
<div id="TitleRow">
<div id="TitleRow">


= <span id="KB170720"></span>WD97: Saving as HTML Removes Hyperlink &quot;Target&quot; Tag =
= <span id="KB170720"></span>WD97: Saving as HTML Removes Hyperlink "Target" Tag =




Line 44: Line 44:
== SYMPTOMS ==
== SYMPTOMS ==


In Microsoft Word, when you open and save an HTML document that contains hyperlinks, Word strips out the optional &quot;Target&quot; tag and value if the document is saved from online layout view.<br />
In Microsoft Word, when you open and save an HTML document that contains hyperlinks, Word strips out the optional "Target" tag and value if the document is saved from online layout view.<br />
<br />
<br />
For example, the following hyperlink with the Target property
For example, the following hyperlink with the Target property
<div class="indent">
<div class="indent">


<A HREF = &quot;HTTP://WWW.MICROSOFT.COM/SUPPORT/&quot; TARGET = &quot;_TOP&quot;>Link Text</A>
<A HREF = "HTTP://WWW.MICROSOFT.COM/SUPPORT/" TARGET = "_TOP">Link Text</A>




Line 56: Line 56:
<div class="indent">
<div class="indent">


<A HREF = &quot;HTTP://WWW.MICROSOFT.COM/SUPPORT/&quot;>Link Text</A>
<A HREF = "HTTP://WWW.MICROSOFT.COM/SUPPORT/">Link Text</A>




Line 87: Line 87:
<li>On the View menu, click HTML Source.</li>
<li>On the View menu, click HTML Source.</li>
<li>In HTML Source view, on the Edit menu, click Replace.</li>
<li>In HTML Source view, on the Edit menu, click Replace.</li>
<li>In the Find What box, type &quot;<A HREF&quot; (without the quotation marks).</li>
<li>In the Find What box, type "<A HREF" (without the quotation marks).</li>
<li>In the Replace With box, type &quot;<!-- <A HREF&quot; (without the quotation marks).</li>
<li>In the Replace With box, type "<!-- <A HREF" (without the quotation marks).</li>
<li>Click Replace All.</li>
<li>Click Replace All.</li>
<li>In the Find What box, type &quot;</A>&quot; (without the quotation marks).</li>
<li>In the Find What box, type "</A>" (without the quotation marks).</li>
<li>In the Replace With box, type &quot;</A> -->&quot; (without the quotation marks).</li>
<li>In the Replace With box, type "</A> -->" (without the quotation marks).</li>
<li>Click Replace All.</li>
<li>Click Replace All.</li>
<li>On the File menu, click Save.</li>
<li>On the File menu, click Save.</li>
Line 107: Line 107:
<li>On the View menu, click HTML Source.</li>
<li>On the View menu, click HTML Source.</li>
<li>In HTML Source view, on the Edit menu, click Replace.</li>
<li>In HTML Source view, on the Edit menu, click Replace.</li>
<li>In the Find What box, type &quot;<!-- <A HREF&quot; (without the quotation marks).</li>
<li>In the Find What box, type "<!-- <A HREF" (without the quotation marks).</li>
<li>In the Replace With box, type &quot;<A HREF&quot; (without quotation marks).</li>
<li>In the Replace With box, type "<A HREF" (without quotation marks).</li>
<li>Click Replace All.</li>
<li>Click Replace All.</li>
<li>In the Find What box, type &quot;</A> -->&quot; (without the quotation marks).</li>
<li>In the Find What box, type "</A> -->" (without the quotation marks).</li>
<li>In the Replace With box, type &quot;</A>&quot; (without the quotation marks).</li>
<li>In the Replace With box, type "</A>" (without the quotation marks).</li>
<li>Click Replace All.</li>
<li>Click Replace All.</li>
<li>On the File menu, click Save.</li>
<li>On the File menu, click Save.</li>

Latest revision as of 11:05, 21 July 2020

Article ID: 170720

Article Last Modified on 1/20/2007



APPLIES TO

  • Microsoft Word 97 Standard Edition



This article was previously published under Q170720

SYMPTOMS

In Microsoft Word, when you open and save an HTML document that contains hyperlinks, Word strips out the optional "Target" tag and value if the document is saved from online layout view.

For example, the following hyperlink with the Target property

<A HREF = "HTTP://WWW.MICROSOFT.COM/SUPPORT/" TARGET = "_TOP">Link Text</A>


will be saved in HTML as:

<A HREF = "HTTP://WWW.MICROSOFT.COM/SUPPORT/">Link Text</A>


CAUSE

The Target tag allows a hyperlink to be opened in a specific frame. Because Word 97 does not support HTML frames, Word removes the TARGET= portion of the hyperlink text.


WORKAROUND

To work around this problem, do one of the following:

  • To retain the Target tag property, edit and save the document in HTML Source view.

    -or-
  • To preserve hyperlinks containing the target property, use the following steps before you edit the HTML document in online layout view in Word 97.

    Step 1: Change the Hyperlinks to Comments

    1. Start Word 97, and open the HTML document.
    2. On the View menu, click HTML Source.
    3. In HTML Source view, on the Edit menu, click Replace.
    4. In the Find What box, type "<A HREF" (without the quotation marks).
    5. In the Replace With box, type "" (without the quotation marks).
    6. Click Replace All.
    7. On the File menu, click Save.
    8. Click the Exit HTML Source toolbar button.

    Step 2: Make Your Changes in Online Layout View

    After you have changed the hyperlinks in your HTML document to comments, you can make changes to your HTML document in online layout. After you have finished editing the HTML document, save the document and then follow the procedure in Step 3 to restore your hyperlinks.

    When the hyperlinks are commented out, they appear as hidden text. (To see hidden text, click the Show/Hide button on the Standard toolbar.)

    Step 3: Restore the Hyperlinks

    1. In Word 97, open your HTML Document.
    2. On the View menu, click HTML Source.
    3. In HTML Source view, on the Edit menu, click Replace.
    4. In the Find What box, type "" (without the quotation marks).
    5. In the Replace With box, type "</A>" (without the quotation marks).
    6. Click Replace All.
    7. On the File menu, click Save.
    8. Click the Exit HTML Source toolbar button.

Following these steps allows you to safely edit your HTML documents in Word 97 while maintaining hyperlinks with the Target property.


Additional query words: 8.0 ia internet assistant

Keywords: kbprb KB170720