HTML <आउटपुट> विशेषता के लिए
उदाहरण
गणना करें और परिणाम को <आउटपुट> तत्व में दिखाएं:
<form oninput="x.value=parseInt(a.value)+parseInt(b.value)">
<input type="range" id="a" value="50">
+<input type="number" id="b" value="25">
=<output name="x" for="a b"></output>
</form>
परिभाषा और उपयोग
for
विशेषता गणना के परिणाम और गणना में प्रयुक्त तत्वों के बीच संबंध को निर्दिष्ट करती है ।
ब्राउज़र समर्थन
तालिका में संख्याएं पहले ब्राउज़र संस्करण को निर्दिष्ट करती हैं जो विशेषता का पूर्ण समर्थन करता है।
Attribute | |||||
---|---|---|---|---|---|
for | 10.0 | 13.0 | 4.0 | 7.0 | 11.5 |
वाक्य - विन्यास
<output for="element_id">
गुण मान
Value | Description |
---|---|
element_id | Specifies a space separated list of ids of one or more elements that specifies the relationship between the result of the calculation, and the elements used in the calculation |
❮ एचटीएमएल <आउटपुट> टैग