<output> Element
The <output> element is used for different types of output, like calculations or script output:Syntax
<form oninput="x.value=parseInt(a.value)+parseInt(b.value)">0
<input type="range" name="a" value="50" />100
+<input type="number" name="b" value="50" />
=<output name="x" for="a b"></output>
</form>
<input type="range" name="a" value="50" />100
+<input type="number" name="b" value="50" />
=<output name="x" for="a b"></output>
</form>
Example:
<!DOCTYPE html><html>
<body>
<form oninput="x.value=parseInt(a.value)+parseInt(b.value)">0
<input type="range" name="a" value="" />100
+<input type="number" name="b" value="" />
=<output name="x" for="a b"></output>
</form>
</body>
</html>
No comments:
Post a Comment