HTML5 Fundamental Syntax

Source: Internet
Author: User

<title>HTML5 Fundamental Syntax</title> HTML5 Fundamental Syntax1Adding Document Structure with HTML5 ' s New Elements1.1Header

is used to contain the headline (s) for a page and/or section. It can also contain
Supplemental information such as logos and navigational aids.

1.2Footer

Contains information about a page and/or sections, such as who wrote it, links to
Related information, and copyright statements.

1.3Nav

Contains the major navigation links for a page and, while not a requirement, is
Often contained by header.

1.4Aside

Contains information that's related to the surrounding content but also exists
Independently, such as a sidebar or pull-quotes.

1.5Section

The section element is a generic container element. When an element was needed only for styling purposes or as a convenience for scripting, authors be encouraged to use the D IV element instead. A General, rule is, the section element was appropriate only if the element ' s contents would was listed explicitly in the Document ' s outline.

1.6Article

is used for self-contained content this could be consumed independently of the page as a whole, such as a blog entry.

1.7Modifying the Document Outline

You had a primary page title and tagline marked up with headings (H1 and H2, respec-tively), but you don ' t want the tag Line included in your document outline.

<HGROUP><H1>HTML5, for fun &amp; Profit

In this example, ONLY/H1/(the largest headline of those headlines) would be shown on the Document Outline.

2Text2.1Emphasizing Text

You want to add emphasis or emphatic stress to text content.

<p>my name is <em>jane</em>, not john.</p>
2.2Adding importance to Text

You want to indicate a span of text this is important.

<p><strong>adding importance to Text</strong></p>
2.3Highlighting Text for Reference

You want to highlight the search term (s) in a list of search results.

<p><mark>highlighting text</mark></p>
2.4Marking up Small Print

You want to offset a legal disclaimer and copyright statement as small print.

<p><small>small print</small></p>
2.5Defining acronyms and abbreviations

You want to provide expanded definitions for acronyms and abbreviations.

<p>i Love working with <abbr title= "Accessible Rich Internet Applications" >ARIA</abbr> roles</p ><p>i Love working with <acronym title= "Accessible Rich Internet Applications" >ARIA</acronym> roles</p><!--not support-->
3Adding Links to Block-level Content

You want to wrap your The site logo and main heading with a single hyperlink.

<a href= "http://www.baidu.com" >    
4Marking up figures and captions

You want to include the illustration with a caption on your Web page.

<figure>      <figcaption>the logo of html5< /figcaption></figure>
5Marking up Dates and times

You want to encode date-time content for machines, but still retain human readability.

<p>published: <time datetime= "2011-01-15" Pubdate>january, 2011</time></p><p>the Class starts at <time datetime= "" >8:00 Am</time>.</p><p>registration opens on <time Datetime= "2011-01-15t08:00-07:00" >january at 8:00am, Mountain time</time>.</p><p> Published: <time>2011-01-15</time></p>

I don ' t see what's the diffience within an without <time>.

6Setting the Stage for Native expanding and collapsing

You want to provide content this can expand and collapse with the user focus (once browsers support it).

<details><summary>upcoming Topics</summary><p>for The New Year, we had a great line up of article S!</p><ul><li>understanding the Outline algorithm</li><li>when to use <code> Hgroup</code></li><li>machine semantics with microdata</li></ul></details>
7Controlling the numbering of Your Lists

You want a ordered list to has numbering different than the default of starting with 1.

<ol start= "2" >   <li>Apple</li>   <li>Bananas</li>   <li>oranges</ Li> </ol>
8Hiding Content to Show later

You have the content that is want to the hide until after a user logs in.

<p hidden>you wouldn ' t see me if you  don ' t log in.</p>
9Making portions of a Page Editable

You want to allow users to directly edit content in the browser.

<article contenteditable> 
TenSetting the Stage for Native Drag-and-drop

You want to allow users to drag and drop content on your Web page.

Author:mlhy

CREATED:2015-10-09 Five 18:31

Emacs 24.5.1 (ORG mode 8.2.10)

HTML5 Fundamental Syntax

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.