XHTML Quick Reference

The basics

Name Element
XHTML content  <html></html> 
Header  <head></head> 
Title  <title></title> 
Body  <body></body> 


Name Element
Link to another page  <a href="url"></a> 
Set a location  <a name="location"></a> 
Link to location  <a href="#location"></a> or <a href="page.html#location"></a> 

Formatting text

Name Element
Strong emphasis  <strong></strong> 
Emphasis  <em></em> 
Bigger text  <big></big> 
Smaller text  <small></small> 
Headings  <h#></h#> 
Paragraph  <p></p> 
Line break  <br /> 


Name Element
Image  <img src="url" alt="???" /> 
Image with width and Height  <img src="url" alt="???" width="#" height="#" /> 


Name Element
Unordered list  <ul></ul> 
Ordered list  <ol></ol> 
List item  <li>Item text</li> 


Name Element
Form content  <form action="url" method="post, get"></form> 
Form input  <input type="text, password, checkbox, radio, image, hidden, submit, reset" /> 
Input name  <input name="value" /> 
Input value  <input value="value" /> 
Default selection  <input checked="checked" /> 
Input size  <input size="#" /> 
Maximum input length  <input maxlength="#" /> 
Selection list  <select name="value"></select> 
No. options shown  <select size="#"></select> 
Multiple choices  <select multiple="multiple"></select> 
Select options  <option value="value">Text</option> 
Selected option  <option selected="selected"></option> 
Option group  <optgroup label="value"></optgroup> 
Multiple line text input  <textarea name="value"></textarea> 
Multi-line size  <textarea rows="#" cols="#"></textarea> 
Multi-line text-wrap  <textarea wrap="off, hard, soft"></textarea> 


Name Element
Table content  <table></table> 
Table row  <tr></tr> 
Table cell  <td></td> 
Cell spanning 2+ column  <td colspan="#"></td> 
Cell spanning 2+ rows  <td rowspan="#"></td> 
Header cells  <th align="left, right, center"></th> 
Header spanning 2+ columns  <th colspan="#"></th> 
Header spanning 2+ rows  <th rowspan="#"></th> 


Name Element
Comments  <!-- comments go here --> 
Style sheet  <style type="text/css"></style> 
External style sheet  <link rel="stylesheet" href="url" /> 
Meta information tags  <meta name="value" content="value" /> 
Horizontal rule  <hr />