π« <form> νκ·Έ
<form>Β νκ·Έλ μΉ νμ΄μ§μμμΒ μ
λ ₯ μμμ μλ―Έ
ν
μ€νΈ νλμ κΈμλ₯Ό μ
λ ₯νκ±°λ, 체ν¬λ°μ€λ λΌλμ€ λ²νΌμ ν΄λ¦νκ³ μ μΆ λ²νΌμ λλ₯΄λ©΄Β λ°±μλ μλ²μ μμμ΄ μ λ¬λμ΄ μ 보λ₯Ό μ²λ¦¬
name: νΌμ μ΄λ¦action: νΌ λ°μ΄ν°κ° μ μ‘λλ λ°±μλ urlmethod: νΌ μ μ‘ λ°©μ (GET / POST)
Β
π« <input> νκ·Έ
<input type="text">
<input type="email">
<input type="password">
<input type="radio">
<input type="file">
<input type="checkbox">
<input type="submit">
<select>
<option>μ΅μ
1</option>
</select>
<textarea></textarea>
<input>νκ·Έμ λ£λ μμ±λ€
<input placeholder="μ΄μ©κ΅¬" value="μ΄μ©κ΅¬" name="age">
placeholder : λ°°κ²½ κΈμ
value : 미리 μ
λ ₯λ κ°
name : μλ² κΈ°λ₯ κ°λ°μ νμν μΈνμ μ΄λ¦μ μ€μ κ°λ₯
- HTML μμ±μΌλ‘ CSS μ λ ν° μ¬μ©
input[type=email] {
color : grey
}
- μ μ‘ λ²νΌ
<button type="submit">μ μ‘</button>
<input type="submit">
<form> νκ·Έ μμ μμ΄μΌ μλ!
Β

λ΅κΈ λ¨κΈ°κΈ°