HTML <input> Tag
ဥပမာ
ထည့်သွင်းမှုနယ်ပယ်သုံးခုပါရှိသော HTML ဖောင်တစ်ခု၊ စာသားအကွက်နှစ်ခုနှင့် ပေးပို့ရန်ခလုတ်တစ်ခု-
<form
action="/action_page.php">
<label for="fname">First name:</label>
<input type="text"
id="fname" name="fname"><br><br>
<label for="lname">Last name:</label>
<input type="text"
id="lname" name="lname"><br><br>
<input type="submit" value="Submit">
</form>
အဓိပ္ပါယ်နှင့် အသုံးပြုမှု
<input>
တဂ်သည် အသုံးပြုသူ ဒေတာ ထည့်သွင်းနိုင်သည့် အကွက်ကို သတ်မှတ်ပေးသည် ။
ဒြပ်စင် သည် <input>
အရေးကြီးဆုံး ပုံစံဒြပ်စင်ဖြစ်သည်။
<input>
အမျိုးအစား attribute ပေါ်မူတည်၍ ဒြပ်စင်ကို နည်းလမ်းများစွာဖြင့် ပြသနိုင်ပါသည် ။
မတူညီသော ထည့်သွင်းမှုအမျိုးအစားများမှာ အောက်ပါအတိုင်းဖြစ်သည်။
<input type="button">
<input type="checkbox">
<input type="color">
<input type="date">
<input type="datetime-local">
<input type="email">
<input type="file">
<input type="hidden">
<input type="image">
<input type="month">
<input type="number">
<input type="password">
<input type="radio">
<input type="range">
<input type="reset">
<input type="search">
<input type="submit">
<input type="tel">
<input type="text">
(မူလတန်ဖိုး)<input type="time">
<input type="url">
<input type="week">
ထည့်သွင်းမှုအမျိုးအစားတစ်ခုစီအတွက် နမူနာများကိုကြည့်ရှု ရန် အမျိုးအစား attribute ကိုကြည့်ပါ။
အကြံပြုချက်များနှင့် မှတ်စုများ
အကြံပြုချက်- , , , , နှင့် အညွှန်းများအတွက် သတ်မှတ်ရန်
<label> tag ကို အမြဲသုံးပါ ။<input type="text">
<input type="checkbox">
<input type="radio">
<input
type="file">
<input type="password">
Browser ပံ့ပိုးမှု
Element | |||||
---|---|---|---|---|---|
<input> | Yes | Yes | Yes | Yes | Yes |
ဂုဏ်တော်
Attribute | Value | Description |
---|---|---|
accept | file_extension audio/* video/* image/* media_type |
Specifies a filter for what file types the user can pick from the file input dialog box (only for type="file") |
alt | text | Specifies an alternate text for images (only for type="image") |
autocomplete | on off |
Specifies whether an <input> element should have autocomplete enabled |
autofocus | autofocus | Specifies that an <input> element should automatically get focus when the page loads |
checked | checked | Specifies that an <input> element should be pre-selected when the page loads (for type="checkbox" or type="radio") |
dirname | inputname.dir | Specifies that the text direction will be submitted |
disabled | disabled | Specifies that an <input> element should be disabled |
form | form_id | Specifies the form the <input> element belongs to |
formaction | URL | Specifies the URL of the file that will process the input control when the form is submitted (for type="submit" and type="image") |
formenctype | application/x-www-form-urlencoded multipart/form-data text/plain |
Specifies how the form-data should be encoded when submitting it to the server (for type="submit" and type="image") |
formmethod | get post |
Defines the HTTP method for sending data to the action URL (for type="submit" and type="image") |
formnovalidate | formnovalidate | Defines that form elements should not be validated when submitted |
formtarget | _blank _self _parent _top framename |
Specifies where to display the response that is received after submitting the form (for type="submit" and type="image") |
height | pixels | Specifies the height of an <input> element (only for type="image") |
list | datalist_id | Refers to a <datalist> element that contains pre-defined options for an <input> element |
max | number date |
Specifies the maximum value for an <input> element |
maxlength | number | Specifies the maximum number of characters allowed in an <input> element |
min | number date |
Specifies a minimum value for an <input> element |
minlength | number | Specifies the minimum number of characters required in an <input> element |
multiple | multiple | Specifies that a user can enter more than one value in an <input> element |
name | text | Specifies the name of an <input> element |
pattern | regexp | Specifies a regular expression that an <input> element's value is checked against |
placeholder | text | Specifies a short hint that describes the expected value of an <input> element |
readonly | readonly | Specifies that an input field is read-only |
required | required | Specifies that an input field must be filled out before submitting the form |
size | number | Specifies the width, in characters, of an <input> element |
src | URL | Specifies the URL of the image to use as a submit button (only for type="image") |
step |
number any |
Specifies the interval between legal numbers in an input field |
type | button checkbox color date datetime-local file hidden image month number password radio range reset search submit tel text time url week |
Specifies the type <input> element to display |
value | text | Specifies the value of an <input> element |
width | pixels | Specifies the width of an <input> element (only for type="image") |
ကမ္ဘာလုံးဆိုင်ရာ အရည်အချင်းများ
<input>
tag သည် HTML တွင် Global Attributes ကို ပံ့ပိုး ပေးပါသည်။
ဖြစ်ရပ်ဂုဏ်တော်များ
<input>
tag သည် HTML ရှိ Event Attributes ကိုလည်း ပံ့ပိုး ပေးပါသည် ။
ဆက်စပ်စာမျက်နှာများ
HTML သင်ခန်းစာ-
- HTML ပုံစံများ
- HTML ဖောင်ဒြပ်စင်များ
- HTML ထည့်သွင်းမှု အမျိုးအစားများ
- HTML ထည့်သွင်းခြင်း အရည်အချင်းများ
- HTML ထည့်သွင်းမှုပုံစံ* ရည်ညွှန်းချက်များ
HTML DOM ရည်ညွှန်းချက်-
- Input Button Object
- Input Checkbox Object
- အရောင်အရာဝတ္ထုကို ထည့်သွင်းပါ။
- ထည့်သွင်းသည့် ရက်စွဲအရာဝတ္ထု
- Datetime Object ကို ထည့်သွင်းပါ။
- DatetimeLocal Object ထည့်သွင်းပါ။
- အီးမေးလ် Object ကို ထည့်သွင်းပါ။
- FileUpload Object ကို ထည့်သွင်းပါ။
- Hidden Object ကို ထည့်သွင်းပါ။
- ရုပ်ပုံအရာဝတ္ထုကို ထည့်သွင်းပါ။
- လအတွင်း အရာဝတ္ထုကို ထည့်သွင်းပါ။
- Input Number Object
- Password Object ကို ထည့်သွင်းပါ။
- Input Range Object
- ရေဒီယိုအရာဝတ္ထုကို ထည့်သွင်းပါ။
- Input Reset Object
- Search Object ကို ထည့်သွင်းပါ။
- Submit Object ကို ထည့်သွင်းပါ။
- စာသား Object ထည့်သွင်းပါ။
- Input Time Object
- URL Object ထည့်သွင်းပါ။
- Input Week Object
မူရင်း CSS ဆက်တင်များ
တစ်ခုမှ