Set width and height for
: hr « Tags « HTML / CSS






Set width and height for


   
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
  "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title></title>
<style type="text/css">
hr {

 width: 10px;
 height: 10px;
 background-color: #777;
}
</style>
</head>

<body>

<hr/>

  <p>This is a text</p>

  
  
</body>
</html>

   
    
  








Related examples in the same category

1.'hr' creates a horizontal rule
2.Horizontal rule
3.Set background color for
4.Horizontal Rule with image
5.Horizontal Rule Example
6.Set line width, size and shade together
7.The hr tag defines a horizontal rule
8.hr margin-left: auto; margin-right: auto; margin-top: 1.25em; margin-bottom: 1.25em;
9.hr width: 10px; height: 10px; background-color: #777;
10.'noshade' causes an 'hr' rule to appear as a solid bar with no shading