Private archive copy · Unofficial site · Content copyright belongs to Runoob Tutorial and the original authors · View Original

HTML object vspace Attribute

HTML The vspace attribute

HTML Object Tag Reference HTML tag

Example

An object with 100-pixel margins on the top and bottom:

This is some text. This is some text. This is some text.

Try it »


Browser support

Internet ExplorerFirefoxOperaGoogle ChromeSafari

All major browsers support the vspace attribute.


Definition and Usage

HTML5 does not support The vspace attribute. Use CSS instead.

In HTML 4.01, The vspace attribute is deprecated.

The vspace attribute specifies the white space above and below an object.


Compatibility notes

In HTML 4.01, The vspace attribute is deprecated. Use CSS instead.

CSS syntax:

CSS example: an object with margins

In our CSS tutorial, you can find more details about The margin attributedetails.


Syntax

Attribute values

Value Description
pixels The white space above and below the object, in pixels.

HTML object Tag Reference HTML tag