메뉴 건너뛰기

HEUKMYO

Html/css

etc accesskey

흑묘 2014.11.14 13:02 read.77

accesskey 속성

정의

accesskey 속성은 사용자 에이전트에 의해 요소를 활성화시키거나 포커스를 갖게끔 하는 단축키를 생성하기 위한 가이드로 사용됩니다.

속성 값

공백문자로 구분된 토큰(token)이며, 유니코드 값이어야 합니다.

예제

<dl>
  <dt><label for="uid">아이디</label></dt>
  <dd class="uid"><input name="id" type="text" id="uid" maxlength="25" class="input_text" title="아이디" accesskey="L"></dd>
  <dt><label for="upw">비밀번호</label> </dt>
  <dd class="upw"><input name="pw" type="password" id="upw" maxlength="16" class="input_text" title="비밀번호"></dd>
</dl>

메모

Accesskey 속성은명세에 Ctrl + Alt 조합키로 사용될수 있다고 명시되어 있지만, 사용자 에이전트별로 차이가 있을 수 있습니다. 또한, 윈도우와 매킨토시에서의 조합키도 다를 수도 있습니다. 다음은 주요 브라우저별 윈도우와 매킨토시에서의조합키입니다.

웹 브라우저 윈도우 매킨토시
Internet Explorer alt -
Firefox 2+ Alt + Shift Ctrl
Opera Shift + Esc
Safari 3+ Alt Ctrl
Google Chrome Alt ( + Shift) Ctrl + Opt
오페라 브라우저는 Shift + Esc 조합키를 누르면 화면과 같이 접근키 목록이 별도의 팝업으로 나타납니다.
[출처]http://html5ref.clearboth.org/doku.php?id=html5:attribute:accesskey
 
위로