The horizontal HTML line is a line that divides the content of a website into two sections. The HTML tag
corresponding does not require a closing element.
What is an HTML horizontal line?
An HTML horizontal line is used to draw a visible and continuous dividing line between two paragraphs or other logical sections in an HTML document. It is defined with the tag (or tag) HTML
and serves to improve the structure and readability of a web page.
is not only a visual dividing line, it also has semantic importance: the element indicates that there is a change of topic or a thematic break.
The HTML tag can theoretically be inserted anywhere inside the element et se passe d’un élément de fermeture. L’abréviation « hr » signifie horizontal ruler (en français : règle horizontale). HTML
accepts all HTML attributes and is supported by all common browsers.
Web Hosting
State-of-the-art web hosting at the best price
- 3x faster, 60% savings
- High availability >99.99%
- Only at IONOS: up to 500 GB included
HTML
: syntax and example
HTML syntax
is simple, because you don't need any attributes or parameters other than the tag:
We can illustrate how the element works with a simple HTML horizontal line example. For this we take a paragraph () et une citation (
) and separate the two sections in our HTML document with a horizontal line. The corresponding code then looks like this:
HTML est le langage de balisage standard pour représenter les pages Web. Il décrit la structure d’une page Web et permet de définir du texte, des images, des liens et d’autres éléments.
« Le HTML est facile à apprendre et offre une base solide pour la création de pages Web. »
html


Customize the appearance of the horizontal line in HTML
It is possible to customize the appearance of a horizontal line in HTML. While the attributes align, color, noshade, size And width were used for this purpose, they are no longer supported since HTML5. Instead, you can now use the attribute style of CSS.
Instead of alignuse this code:
HTML est le langage de balisage standard pour les documents destinés à être affichés sur le Web. Il décrit la structure d’une page Web et permet de définir du texte, des images, des liens et d’autres éléments.
« Le HTML est facile à apprendre et offre une base solide pour la création de sites Web. »
html
To change the color of the horizontal HTML line, use the property color with the attribute style :
HTML est le langage de balisage standard pour les documents destinés à être affichés sur le Web. Il décrit la structure d’une page Web et permet de définir du texte, des images, des liens et d’autres éléments.
« HTML est facile à apprendre et offre une base solide pour la création de pages Web. »
html
Instead of noshadeuse the following code to include a horizontal line without shadow:
Une ligne horizontale normale :
Avec CSS :
html
To change the heightuse height :
Une ligne horizontale normale :
Une ligne horizontale d’une hauteur de 50 pixels :
html
You define the width of the HTML horizontal line with the parameter width :
Une ligne horizontale normale :
Une ligne horizontale d’une largeur de 30 % :
html
Domain name
Your domain in one click
- 1 Wildcard SSL certificate per contract
- Included Domain Connect feature for simplified DNS setup

