HTML5 published and modified time

后端 未结 1 1092
再見小時候
再見小時候 2021-01-14 08:46

I’d like to include published and modified time of an article. I looked through documentation and cannot find info about this.

So far, I got this:



        
相关标签:
1条回答
  • 2021-01-14 09:07

    The time element can’t have a pubdate attribute. (It was part of early drafts, but it got removed.)

    HTML5 itself doesn’t provide a way to specify that a date is a publication or a modification date.

    If you need to specify this in a machine-readable way, you could use an appropriate vocabulary. For example, the vocabulary Schema.org defines the properties datePublished and dateModified for CreativeWork (and its sub-types).

    0 讨论(0)
提交回复
热议问题