ITSourceCode.com

We Exist to Provide 100% Free Source Code and Tutorials

Custom Search

08-CSS Dimension Properties

The CSS dimension properties allow you to control the height and width of an element.

Setting height and width

The height and width properties are used to set the height and width of an element.

  1. <!DOCTYPE html>
  2. div {
  3. width: 5000px;
  4. height: 1000px;
  5. border: 5px solid #73AD21;
  6. }
  7. </head>
  8.  
  9. <h2>Set height and width of an Element given here:</h2>
  10.  
  11. <div>
  12. This div element has a height of 1000px and a width of 5000px.
  13. </div>
  14.  
  15. </body>
  16. </html>

 

Set height and width of an Element given here:

This div element has a height of 1000px and a width of 5000px.

 

Facebook Comments

Check Your Domain Ranking

Leave a Reply

Your email address will not be published. Required fields are marked *

ITSourceCode.com © 2016 Frontier Theme

Subscribe For Latest Updates

Signup for our newsletter and get notified when we publish new articles for free!