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

HTML onresize Event Attribute

HTML onresize Event Attribute

HTML Event Attributes HTML Event Attributes

Example

Run a script when the window is resized:

Try it »


Browser support

Internet ExplorerFirefoxOperaGoogle ChromeSafari

All major browsers support the onresize event attribute


Definition and Usage

The onresize attribute is triggered when the window is resized.

The onresize attribute is often used to resize the window.


Differences between HTML 4.01 and HTML5

None.


Syntax

<

element

onresize="

script

">

HTML Event Attributes HTML Event Attributes