검색결과 리스트
2011/09/19 에 해당되는 글 2건
- 2011.09.19 6.7 HTML5 Input Type: Range
- 2011.09.19 6.6 HTML5 Input Type: Email, URL, Phone
2011. 9. 19. 12:30
Range는 특정 범위 값을 입력할 때 사용하는 필드입니다. 역시나 Range 역시 입력 환경이 제한적인 모바일 환경에서 사용이 특히 유용합니다. 그래서인지 지금 우선 지원하는 브라우저들도 모바일 환경에 강한 브라우저 들입니다.
Range의 사용방법은 아래와 같습니다.
<input id="test" type="range"/>
아래와 같이 사용했을 때 현재 지원하는 브라우저에서 보여지는 모습입니다.
현재 이 Range를 지원하는 웹 브라우저는 Chrome, Safari, Opera 등입니다.
| Browsers | Render Range input as Slider |
|---|---|
| IE 9 | |
| Firefox 4 | |
| Safari 5 | ✓ |
| Chrome 8 | ✓ |
| Opera 11 | ✓ |
Range를 사용하기 위해서는 몇 가지 속성을 더 정확하게 써주는것이 좋습니다. 현재 값이나 최대 값, 최소 값 같은 것들입니다.
<input id="slider1" type="range" min="100" max="500" step="10" />
| Attribute | Descriptions |
|---|---|
| value | Value is a common attribute of "Input" element. The value can be any valid floating point number, not neccessary must be an integer number. Default value is minimum value plus half of the maximum value. |
| min | Minimum value of the range. Default minimum value is 0. |
| max | Maximum value of the range. Default maximum value is 100. |
| step | This is Step scale factor of the slider, default value is 1 and only allowing integer number unless minimum value is non integer number. |
| list | List is the DataList in the past lesson. Datalist can be incorporated into Range type input, however, none of the browser has implemented this feature as of writing. |
|
|
현재 한국마이크로소프트에서 Evangelist로 근무하고 있으며 국내 유수의 대기업 프로젝트에 참여했던 경험과 Microsoft MVP로 다년간 활동했습니다. |
HTML5 강좌 전체 목록
- HTML5 DocType의 정의
- HTML5 Header stuff
- Audio
- Video
- Canvas
Canvas: Rectangle
Canvas: Shadow
Canvas: Path
Canvas: Image
Canvas: Text - Web form 2.0
Input Attr: Placeholder
Input Attr: Autofocus
Input Attr: Required field
Input Attr: DataList
Input Type: Search
Input Type: Email, URL, Phone
Input Type: Range
Input Type: Number
Input Type: Date
Input Type: Color - Towards Semantic Web
Semantic <mark>
Semantic <time>
Semantic <meter>
Semantic <progress>
Semantic <section>
Semantic <header>
Semantic <footer>
Semantic <nav>
Semantic <article>
Semantic <aside>
2011. 9. 19. 08:30
Email, Phone, URL등 정형화된 입력 유형의 입력을 도와주는 타입이 HTML5에서 추가 되었습니다. 입력하려는 내용이 구체적으로 명시되면서 입력을 적극적으로 도와 줄 수 있게 되었는데 주로 입력이 불편한 모바일 환경에서 적극적으로 활용되고 있습니다.
아래와 같이 email, url, tel 등 타입을 명시하게 되면 HTML5를 지원하는 웹 브라우저는 여기에 적합한 입력기 형태를 노출해 줍니다. 현재로는 주로 모바일 환경에서 이를 지원하도록 되었습니다.
<input id="email" type="email"/>
<input id="website" type="url"/>
<input id="phone" type="tel" />

HTML5 강좌 전체 목록
아래와 같이 email, url, tel 등 타입을 명시하게 되면 HTML5를 지원하는 웹 브라우저는 여기에 적합한 입력기 형태를 노출해 줍니다. 현재로는 주로 모바일 환경에서 이를 지원하도록 되었습니다.
<input id="email" type="email"/>
<input id="website" type="url"/>
<input id="phone" type="tel" />
아래는 안드로이드 계열의 폰과 iOS계열의 스마트 폰에서 위의 폼을 접근했을 때 유형 별로 어떤 입력기가 출력되는지를 볼 수 있습니다.
|
|
현재 한국마이크로소프트에서 Evangelist로 근무하고 있으며 국내 유수의 대기업 프로젝트에 참여했던 경험과 Microsoft MVP로 다년간 활동했습니다. |
HTML5 강좌 전체 목록
- HTML5 DocType의 정의
- HTML5 Header stuff
- Audio
- Video
- Canvas
Canvas: Rectangle
Canvas: Shadow
Canvas: Path
Canvas: Image
Canvas: Text - Web form 2.0
Input Attr: Placeholder
Input Attr: Autofocus
Input Attr: Required field
Input Attr: DataList
Input Type: Search
Input Type: Email, URL, Phone
Input Type: Range
Input Type: Number
Input Type: Date
Input Type: Color - Towards Semantic Web
Semantic <mark>
Semantic <time>
Semantic <meter>
Semantic <progress>
Semantic <section>
Semantic <header>
Semantic <footer>
Semantic <nav>
Semantic <article>
Semantic <aside>
댓글을 달아 주세요