Answers for "<hr> html"

5

how to change the color of the hr tag in html

<style>       
    hr{
        height: 1px;
        background-color: #ccc;
        border: none;
    }
</style>
Posted by: Guest on September-02-2020
5

hr tag

<hr style="height:2px;border-width:0;color:gray;background-color:gray">
Posted by: Guest on April-04-2021
4

how to style an hr tag

/* Red border */
hr.new1 {
  border-top: 1px solid red;
}

/* Dashed red border */
hr.new2 {
  border-top: 1px dashed red;
}

/* Dotted red border */
hr.new3 {
  border-top: 1px dotted red;
}

/* Thick red border */
hr.new4 {
  border: 1px solid red;
}

/* Large rounded green border */
hr.new5 {
  border: 10px solid green;
  border-radius: 5px;
}
Posted by: Guest on June-28-2020
16

horizontal line html

<!-- code -->

<hr>

<!-- code -->
Posted by: Guest on February-18-2020
1

hr tag

The <hr> tag in HTML stands for horizontal rule 
and is used to insert a horizontal rule or a thematic break in an HTML page 
to divide or separate document sections. 
The <hr> tag is an empty tag and it does not require an end tag.
Posted by: Guest on June-09-2021
2

which is right <hr> or <hr/> in html

<hr> <!--   it represents a horizontal line break, in HTML4.0 we use <hr>, 
            in XHTML1.0 we use <hr/>,  in HTML5(which is the current version of 
            HTML) we can use both <hr> and <hr/>    
       -->
Posted by: Guest on September-10-2020

Browse Popular Code Answers by Language