Latest web development tutorials

HTML output for properties

Tag Reference HTML output HTML <output> tag

Examples

The calculation results are shown in lt; output> element:

<form oninput="x.value=parseInt(a.value)+parseInt(b.value)">0
<input type="range" id="a" value="50">100
+<input type="number" id="b" value="50">
=<output name="x" for="a b"></output>
</form>

try it"

Browser Support

Internet ExplorerFirefoxOperaGoogle ChromeSafari

Firefox, Opera, Chrome and Safari browser support for properties.

Note: Internet Explorer browser does not support <output> tag.


Definition and Usage

for attribute specifies the relationship between the elements and the results used in the calculations between.


Differences between HTML 4.01 and HTML5

<Output> tag is new in HTML5 tags.


grammar

<output for="element_id">

Property Value

描述
element_id 规定一个或多个元素的 id 列表,以空格分隔。这些元素描述了计算中使用的元素与计算结果之间的关系。


Tag Reference HTML output HTML <output> tag