लोड हो रहा है...
HTML form elements
A form is a toolbox. Different questions need different controls.
सीधा उत्तर
Use label + controls such as input, textarea, select, and button. Group with fieldset and legend. Every control needs an accessible name (usually via label).
📊 Common form pieces
| Element | Role |
|---|---|
| label | Names a control for humans and assistive tech |
| input | Many single-line / toggle controls (see Input Types) |
| textarea | Multi-line text |
| select / option | Choose from a list |
| button | Actions (submit/reset/button) |
| fieldset / legend | Group related controls with a title |
Mixed controls sketch
html
HTML Code
<form action="/profile" method="post">
<fieldset>
<legend>Profile</legend>
<label for="bio">Bio</label>
<textarea id="bio" name="bio" rows="4"></textarea>
<label for="level">Level</label>
<select id="level" name="level">
<option value="beginner">Beginner</option>
<option value="middle">Middle</option>
</select>
<button type="submit">Save</button>
</fieldset>
</form>
आज़माएँ
- fieldset + legend
- textarea + select with labels
- submit button
- keyboard reach each control
आसान गलतियाँ
- controls without labels
- div title instead of legend
- submit outside form
सारांश
- match control to question
- always label
- fieldset/legend groups
- details next lessons
🧠 अपने ज्ञान की परीक्षा करें
शुरू करने के लिए तैयार
अपने ज्ञान की परीक्षा करें
इस इंटरैक्टिव क्विज़ के साथ अपनी चुनौती लें और देखें कि आप विषय को कितनी अच्छी तरह समझते हैं
5
प्रश्न
70%
पास करने के लिए
∞
समय
∞
प्रयास
📝 निर्देश
- हर प्रश्न को ध्यान से पढ़ें
- हर प्रश्न के लिए सबसे अच्छा उत्तर चुनें
- आप जितनी बार चाहें क्विज़ दोबारा दे सकते हैं
- आपकी प्रगति शीर्ष पर दिखाई जाएगी