Center Alignment | WebReference

Center Alignment

HTML 4.01 Element Reference

By Lee Underwood

Return to HTML 4.01 element index page

Name: Center Alignment

<center> ... </center>

Description: Centers the text within the margins of the document.

Browser Compatibility: NN: 1.0+ / IE: 2.0+ / Opera: 4+

Attributes:
  • class
  • dir
  • id
  • lang
  • onclick
  • ondblclick
  • onkeydown
  • onkeypress
  • onkeyup
  • onmousedown
  • onmousemove
  • onmouseout
  • onmouseover
  • onmouseup
  • style
  • title

Code Example:

<center>This text would be centered on the page.</center>

Comments: Deprecated in favor of Style Sheets.




Created: March 15, 2005

URL: http://webreference.com/html/reference/specs/