Download HTML Cheat Sheet - Australian Education International

Survey
yes no Was this document useful for you?
   Thank you for your participation!

* Your assessment is very important for improving the workof artificial intelligence, which forms the content of this project

Document related concepts

URL redirection wikipedia , lookup

Transcript
Shared Services Centre - Web Accessibility Testing team
HTML cheat sheet
<br>
The BR element adds a line break and forces content to begin on a new line; avoid overusing
this tag.
Example:
This is on line one<br>
This is now on line two
<table>
The TABLE element must be accompanied by a closing tag, table header tags, scope attribute
and a caption tag.




Each table must have a <caption> element describing the data.
Each table must have one or more <th> table header row elements.
Each table can have one or more <tr> table row elements.
Each row can have one or more <td> table data elements.
Example:
<table>
<caption>This is a caption</caption>
<tr><th scope="col">This is a column header</th></tr>
<tr><td>This is row data</td></tr>
</table>
<img>
The IMG element must always contain an ALT attribute.


If an image is decorative and does not solely convey meaning, the ALT text description
should be blank.
If an image does convey meaning and is a crucial part of the page content, a succinct
ALT text description must be provided.
Example (decorative image):
<img src="border.gif" alt="">
Example (image that conveys meaning):
<img src="bridge.gif" alt="a view of Sydney Harbour Bridge">
Page 1 of 3
Shared Services Centre - Web Accessibility Testing team
<ul>
The UL element represents an unordered list using regular bullet points.


Each unordered list must have a closing tag.
List items must be wrapped in <li> and end with a </li>
Example:
<ul>
<li>Eggs</li>
<li>Milk</li>
<li>Bread</li>
</ul>
<ol>
The OL element represents an ordered list by using a sequential numbering system.


Each ordered list must have a closing tag.
List items must be wrapped in <li> and end with a </li>
Example:
<ol>
<li>Eggs</li>
<li>Milk</li>
<li>Bread</li>
</ol>
<h1> - <h5>
The H1 to H5 heading levels provide a structured hierarchy for web content; assistive
technology (AT) users rely on this semantic markup to navigate, and quickly determine the
purpose of the page.




Do not use a <H1> heading level, as each AEI webpage already has one.
Headings should follow a numbered sequence.
Only use the heading levels that are required for the page content (e.g. H2 and h3).
Each heading level must have a corresponding closing tag.
Example:
<h1>Heading
<h2>Heading
<h3>Heading
<h4>Heading
<h5>Heading
1</h1>
2</h2>
3</h3>
4</h4>
5</h5>
Page 2 of 3
Shared Services Centre - Web Accessibility Testing team
<a href="">
A link may navigate a user to another location/section in the same webpage (anchor link), or to
another webpage within the current website (local link), or to another website (external link).


Screen reader users can access all the links of a page in a separate window; avoid vague
link text such as ‘click here’ or ‘more’.
If the link opens a document, describe the type of document and file size in the link text.
Example:
<a href="link to webpage.html">link text to display</a>
<a href="link to pdf document.pdf">link text to display [PDF document 200kb]</a>
Page 3 of 3