<tfoot id='O9oYg'></tfoot>
  • <i id='O9oYg'><tr id='O9oYg'><dt id='O9oYg'><q id='O9oYg'><span id='O9oYg'><b id='O9oYg'><form id='O9oYg'><ins id='O9oYg'></ins><ul id='O9oYg'></ul><sub id='O9oYg'></sub></form><legend id='O9oYg'></legend><bdo id='O9oYg'><pre id='O9oYg'><center id='O9oYg'></center></pre></bdo></b><th id='O9oYg'></th></span></q></dt></tr></i><div id='O9oYg'><tfoot id='O9oYg'></tfoot><dl id='O9oYg'><fieldset id='O9oYg'></fieldset></dl></div>
  • <small id='O9oYg'></small><noframes id='O9oYg'>

      <legend id='O9oYg'><style id='O9oYg'><dir id='O9oYg'><q id='O9oYg'></q></dir></style></legend>
        <bdo id='O9oYg'></bdo><ul id='O9oYg'></ul>

        我应该使用哪个 HTML5 标签来标记作者姓名?

        时间:2023-07-31

            <tbody id='JixqV'></tbody>
        1. <small id='JixqV'></small><noframes id='JixqV'>

            <i id='JixqV'><tr id='JixqV'><dt id='JixqV'><q id='JixqV'><span id='JixqV'><b id='JixqV'><form id='JixqV'><ins id='JixqV'></ins><ul id='JixqV'></ul><sub id='JixqV'></sub></form><legend id='JixqV'></legend><bdo id='JixqV'><pre id='JixqV'><center id='JixqV'></center></pre></bdo></b><th id='JixqV'></th></span></q></dt></tr></i><div id='JixqV'><tfoot id='JixqV'></tfoot><dl id='JixqV'><fieldset id='JixqV'></fieldset></dl></div>
              <bdo id='JixqV'></bdo><ul id='JixqV'></ul>
                  <tfoot id='JixqV'></tfoot>
                  <legend id='JixqV'><style id='JixqV'><dir id='JixqV'><q id='JixqV'></q></dir></style></legend>

                • 本文介绍了我应该使用哪个 HTML5 标签来标记作者姓名?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着跟版网的小编来一起学习吧!

                  问题描述

                  例如博客文章或文章.

                  <article>
                  <h1>header<h1>
                  <time>09-02-2011</time>
                  <author>John</author>
                  My article....
                  </article>
                  

                  author 标签并不存在……那么,作者常用的 HTML5 标签是什么?谢谢.

                  The author tag doesn't exist though... So what is the commonly used HTML5 tag for authors? Thanks.

                  (如果没有,不应该有一个吗?)

                  (If there isn't, shouldn't there be one?)

                  推荐答案

                  两者 rel="author"<address> 正是为此目的而设计的.两者都在 HTML5 中受支持.规范告诉我们 rel="author" 可用于 <link> <a><area> 元素.Google 还推荐 用法.结合使用 <address>rel="author" 似乎是最佳选择.HTML5 最适合包装 <article> <header> 中的标题和署名信息,如下所示:

                  Both rel="author" and <address> are designed for this exact purpose. Both are supported in HTML5. The spec tells us that rel="author" can be used on <link> <a>, and <area> elements. Google also recommends its usage. Combining use of <address> and rel="author" seems optimal. HTML5 best affords wrapping <article> headlines and bylines info in a <header> like so:

                  <article>
                      <header>
                          <h1 class="headline">Headline</h1>
                          <div class="byline">
                              <address class="author">By <a rel="author" href="/author/john-doe">John Doe</a></address> 
                              on <time pubdate datetime="2011-08-28" title="August 28th, 2011">8/28/11</time>
                          </div>
                      </header>
                  
                      <div class="article-content">
                      ...
                      </div>
                  </article>
                  

                  • pubdate 属性表明这是发布日期.

                    • The pubdate attribute indicates that that is the published date.

                      title 属性是可选的天桥.

                      署名信息也可以包装在 <footer>"><文章>

                      The byline info can alternatively be wrapped in a <footer> within an <article>

                      如果你想添加 hcard 微格式,我会这样做就像这样:

                      If you want to add the hcard microformat, then I would do so like this:

                      <article>
                          <header>
                              <h1 class="headline">Headline</h1>
                              <div class="byline vcard">
                                  <address class="author">By <a rel="author" class="url fn n" href="/author/john-doe">John Doe</a></address> 
                                  on <time pubdate datetime="2011-08-28" title="August 28th, 2011">on 8/28/11</time>
                              </div>
                          </header>
                      
                          <div class="article-content">
                          ...
                          </div>
                      </article>
                      

                      这篇关于我应该使用哪个 HTML5 标签来标记作者姓名?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持跟版网!

                  上一篇:标签的 HTML5 角色属性 下一篇:i 标签的 Alt 或标题属性

                  相关文章

                • <small id='7Prq5'></small><noframes id='7Prq5'>

                    • <bdo id='7Prq5'></bdo><ul id='7Prq5'></ul>

                    <legend id='7Prq5'><style id='7Prq5'><dir id='7Prq5'><q id='7Prq5'></q></dir></style></legend>

                      <i id='7Prq5'><tr id='7Prq5'><dt id='7Prq5'><q id='7Prq5'><span id='7Prq5'><b id='7Prq5'><form id='7Prq5'><ins id='7Prq5'></ins><ul id='7Prq5'></ul><sub id='7Prq5'></sub></form><legend id='7Prq5'></legend><bdo id='7Prq5'><pre id='7Prq5'><center id='7Prq5'></center></pre></bdo></b><th id='7Prq5'></th></span></q></dt></tr></i><div id='7Prq5'><tfoot id='7Prq5'></tfoot><dl id='7Prq5'><fieldset id='7Prq5'></fieldset></dl></div>

                      <tfoot id='7Prq5'></tfoot>