/

HTML / CSS / JavaScript Tutorial

HTML Standard attribute: height

[this page | pdf | back links]

The HTML height attribute indicates the height of an element. It applies to <canvas>, <embed>, <iframe>, <img>, <input>, <object> and <video> elements.

 

Valid attribute values (when used with <canvas>, <embed>, <iframe>, <img>, <input>, <object> and <video> elements) include:

 

Value

Description

number

Width of element or embedded content in pixels, e.g. width="20"

percentage

Width as a percentage of surrounding element, e.g. width="30%"

 


NAVIGATION LINKS
Contents | Prev | Next | HTML Attributes


Desktop view | Switch to Mobile