HTML 导入与导出

When you export a file to an HTML document, the description and the user-defined file properties are included as META tags between the HEAD tags of the exported document. META tags are not displayed in a Web browser, and are used to include information, such as keywords for search engines on your Web page. To set the properties of the current document, choose File - Properties, click the Description or Custom Properties tabs, and then type the information you want.

当文件以 HTML 文档格式导出时,以下文件属性将被转换为 META 标记:

ODF Property

HTML Tags

Title

</p> </td> </tr> <tr> <td rowspan="" colspan="" dir="auto"> <p id="par_id3153778" class="paragraphintable" dir="auto">主题</p> </td> <td rowspan="" colspan="" dir="auto"> <p id="par_id3147228" class="paragraphintable" dir="auto"><META NAME="CLASSIFICATION" CONTENT="Field Content"></p> </td> </tr> <tr> <td rowspan="" colspan="" dir="auto"> <p id="par_id3154908" class="paragraphintable" dir="auto">关键字</p> </td> <td rowspan="" colspan="" dir="auto"> <p id="par_id3156422" class="paragraphintable" dir="auto"><META NAME="KEYWORDS" CONTENT="Field Content"></p> </td> </tr> <tr> <td rowspan="" colspan="" dir="auto"> <p id="par_id3151041" class="paragraphintable" dir="auto">说明</p> </td> <td rowspan="" colspan="" dir="auto"> <p id="par_id3125863" class="paragraphintable" dir="auto"><META NAME="DESCRIPTION" CONTENT="Field Content"></p> </td> </tr> <tr> <td rowspan="" colspan="" dir="auto"> <p id="par_id3159149" class="paragraphintable" dir="auto">Custom Properties</p> </td> <td rowspan="" colspan="" dir="auto"> <p id="par_id3157892" class="paragraphintable" dir="auto"><META NAME="Custom field name" CONTENT="Custom field content"></p> </td> </tr> </table> <br> <div class="note"> <div class="noteicon" dir="auto"><img src="media/icon-themes/res/helpimg/note.svg" alt="note" style="width:40px;height:40px;"></div> <div class="notetext"><p id="par_id3155855" dir="auto">当导入含有 META 标记的 HTML 文件时,标记的内容将被加入到 LibreOffice 的相应文件属性框中。</p></div> </div> <br> <div class="tip"> <div class="noteicon" dir="auto"><img src="media/icon-themes/res/helpimg/tip.svg" alt="tip" style="width:40px;height:40px;"></div> <div class="notetext"><p id="par_id0926200812164481" dir="auto">关键字之间必须用逗号隔开。关键字可以包含空白字符或分号。</p></div> </div> <br> <h3 id="hd_id3163822" dir="auto">导入提示</h3> <p id="par_id3155307" class="paragraph" dir="auto">当导入 HTML 文档时,以下 META 标记将被自动转换为 LibreOffice 字段: <META HTTP-EQUIV="REFRESH"...> 和 <META NAME="..." ...>,其中,NAME 相当于 AUTHOR、CREATED、CHANGED、CHANGEDBY、DESCRIPTION、KEYWORDS 或 CLASSIFICATION。</p> <p id="par_id3146146" class="paragraph" dir="auto">位于 TABLE 标记之前的脚本、注释和 META 标记被插入到表格的第一个单元格中。</p> <p id="par_id3155366" class="paragraph" dir="auto">HTML 文档页眉中的脚本和 META 标记将被导入并锁定到文档的第一个段落中。</p> <p id="par_id3152885" class="paragraph" dir="auto">要设置有关导入 HTML 标记的选项,请选择「<span id="swlnsystextshared01about_meta_tagsxml_1" class="switchinline"><span hidden="true" id="MACtextshared01about_meta_tagsxml_1" class="MAC"><span class="emph">LibreOffice - 偏好设置</span></span><span hidden="true" id="defaulttextshared01about_meta_tagsxml_1"><span class="emph">工具 - 选项</span></span></span><span class="emph"> - 加载/保存 - HTML 兼容性</span>」。 除了 <META NAME="GENERATOR"...> (该标记被忽略) 以外,所有含有「HTTP-EQUIV」或「NAME」的已知 META 标记都将以 LibreOffice 批注的形式导入。</p> <h3 id="hd_id3163717" dir="auto">导出提示</h3> <p id="par_id3159180" class="paragraph" dir="auto">文档中第一段起始处的批注和脚本字段被导出到 HTML 文档的页眉。如果文档的起始处是表格,则表格的第一个单元格中的第一段被导出到 HTML 文档的页眉。</p> </div> <div id="SearchFrame"></div> <div id="DonationFrame"></div> <footer><div id="DEBUG" class="debug"> <h3 class="bug">Help content debug info:</h3> <p dir="auto">This page is: <a href="https://opengrok.libreoffice.org/xref/help/source/text/shared/01/about_meta_tags.xhp" target="_blank">/text/shared/01/about_meta_tags.xhp</a></p> <p dir="auto">Title is: HTML 导入与导出</p> <p id="bm_module" dir="auto"></p> <p id="bm_system" dir="auto"></p> <p id="bm_HID" dir="auto"></p> </div></footer> </body> </html>