새롭게 배운 attribute 나 element 들을 정리하려는 목적으로
패션 설문 조사 구글 폼을 HTML을 이용해서 만들어볼거에요. 그냥 단순하게 모양만 따라 하는 거에요😂🤣
<label for="name">이름을 입력해주세요.</label>
<input type="text" id="name" autofocus>
화면이 열렸을 때, text로 포커스가 깜박이게 만드는 것입니다.
<p>1.평소에 패션에 투자 하시나요??</p>
<input type="radio" name="interest" id="no" value="no">
<label for="no">아니요</label>
<input type="radio" name="interest" id="yes" value="yes">
<label for="yes">네</label>
id
와 for
는 연결되있어야 됨. name
을 통일하면, 둘중에 하나만 클릭할 수 있게됨.value
를 설정해줘야 데이터 잘 넘어감~<label for="sex">성별을 선택해주세여</label>
<select name="sex" id="sex">
<option value="">선택></option>
<option value="f">여자</option>
<option value="m">남자></option>
<option value="xx" disabled>고양이</option>
</select>
select
는 option
꼭 필요disabled
이것은 option엔 있지만, 선택은 못함