Prior to HTML5, the
tag was used purely for presentational purposes (i.e. The HTML horizontal rule
tag is a way to create a break in your web page content and draw a line across the page. Unlike the other tags you have learned, the horizontal tag does not have an open an closing tag and does not wrap around content. HR tag in HTML 4.01 and HTML5? Instead of a color, define a background image for your horizontal rule so that it looks exactly as you want it to, but still displays semantically in your markup. If you're using line dividers (horizontal rules) within your web page, you can change the color, width and height of the line dividers by adding some attributes to your
HTML code. good resource. While it may still be displayed as a horizontal rule in visual browsers, this element is now defined in semantic terms, rather than presentational terms, so if you wish to draw a horizontal line, you should do so using appropriate CSS. It has been over used in stylistic design and should be used to separate things that are not related. To insert thematic break for content, you may use HTML HR tag. : width: pixels or % Deprecated − Specifies the width of the horizontal rule. The