jquery鍵盤按鍵提示代碼



113 450 151



特效描述:鍵盤按鍵提示,Jquery.hotkey鍵盤監聽事件,支持多復合鍵事件,調用簡單。

代碼結構

1. 引入JS

<script src="jquery-1.4.2.js"></script>
<script src="jquery.hotkeys.js"></script>

2. HTML代碼

<h1>jQuery.HotKeys.Testing.</h1>
<h2><span style="color:red;">請按對應下方相應的鍵盤按鍵</span></h2>
<h2>測試平臺:</h2>
<div id="platform-details"></div>
<h2>Project Home: <a href="http://code.google.com/p/js-hotkeys/">http://code.google.com/p/js-hotkeys/</a></h2>
<div id="report-area">
<h2>Special Keys</h2><div id="_esc" class="eventNotifier">esc</div><div id="_tab" class="eventNotifier">tab</div><div id="_space" class="eventNotifier">space</div><div id="_return" class="eventNotifier">return</div><div
id="_backspace" class="eventNotifier">backspace</div><div id="_scroll" class="eventNotifier">scroll</div><div id="_capslock" class="eventNotifier">capslock</div><div id="_numlock" class="eventNotifier">numlock</div><div id=
"_pause" class="eventNotifier">pause</div><div id="_insert" class="eventNotifier">insert</div><div id="_home" class="eventNotifier">home</div><div id="_del" class="eventNotifier">del</div><div id="_end" class="eventNotifier">
end</div><div id="_pageup" class="eventNotifier">pageup</div><div id="_pagedown" class="eventNotifier">pagedown</div><div id="_left" class="eventNotifier">left</div><div id="_up" class="eventNotifier">up</div><div id="_right" 
class="eventNotifier">right</div><div id="_down" class="eventNotifier">down</div><div id="_f1" class="eventNotifier">f1</div><div id="_f2" class="eventNotifier">f2</div><div id="_f3" class="eventNotifier">f3</div><div id="_f4" 
class="eventNotifier">f4</div><div id="_f5" class="eventNotifier">f5</div><div id="_f6" class="eventNotifier">f6</div><div id="_f7" class="eventNotifier">f7</div><div id="_f8" class="eventNotifier">f8</div><div id="_f9" class=
"eventNotifier">f9</div><div id="_f10" class="eventNotifier">f10</div><div id="_f11" class="eventNotifier">f11</div><div id="_f12" class="eventNotifier">f12</div><div style="clear: both;"/>
<h2>0-9 Digits</h2>
<div id="_1" class="eventNotifier">1</div>
<div id="_2" class="eventNotifier">2</div>
<div id="_3" class="eventNotifier">3</div>
<div id="_4" class="eventNotifier">4</div>
<div id="_5" class="eventNotifier">5</div>
<div id="_6" class="eventNotifier">6</div>
<div id="_7" class="eventNotifier">7</div>
<div id="_8" class="eventNotifier">8</div>
<div id="_9" class="eventNotifier">9</div>
<div id="_0" class="eventNotifier">0</div>
<div style="clear: both;"/>
<h2>A-Z Letters</h2>
<div id="_a" class="eventNotifier">a</div>
<div id="_b" class="eventNotifier">b</div><div id="_c" class="eventNotifier">c</div><div id="_d" class="eventNotifier">d</div><div id="_e" class="eventNotifier">e</div><div id="_f" class="eventNotifier">
f</div><div id="_g" class="eventNotifier">g</div><div id="_h" class="eventNotifier">h</div><div id="_i" class="eventNotifier">i</div><div id="_j" class="eventNotifier">j</div><div id="_k" class="eventNotifier">k</div><div id=
"_l" class="eventNotifier">l</div><div id="_m" class="eventNotifier">m</div><div id="_n" class="eventNotifier">n</div><div id="_o" class="eventNotifier">o</div><div id="_p" class="eventNotifier">p</div><div id="_q" class=
"eventNotifier">q</div><div id="_r" class="eventNotifier">r</div><div id="_s" class="eventNotifier">s</div><div id="_t" class="eventNotifier">t</div><div id="_u" class="eventNotifier">u</div><div id="_v" class="eventNotifier">v
</div><div id="_w" class="eventNotifier">w</div><div id="_x" class="eventNotifier">x</div><div id="_y" class="eventNotifier">y</div><div id="_z" class="eventNotifier">z</div><div style="clear: both;"/><h2>Special Modifiers</h2
><div style="clear: both;"/><strong>Ctrl</strong><div id="_Ctrl_a" class="eventNotifier">Ctrl+a</div><div id="_Ctrl_b" class="eventNotifier">Ctrl+b</div><div id="_Ctrl_c" class="eventNotifier">Ctrl+c</div><div id="_Ctrl_d" 
class="eventNotifier">Ctrl+d</div><div id="_Ctrl_e" class="eventNotifier">Ctrl+e</div><div id="_Ctrl_f" class="eventNotifier">Ctrl+f</div><div id="_Ctrl_g" class="eventNotifier">Ctrl+g</div><div id="_Ctrl_h" class=
"eventNotifier">Ctrl+h</div><div id="_Ctrl_i" class="eventNotifier">Ctrl+i</div><div id="_Ctrl_j" class="eventNotifier">Ctrl+j</div><div id="_Ctrl_k" class="eventNotifier">Ctrl+k</div><div id="_Ctrl_l" class="eventNotifier">
Ctrl+l</div><div id="_Ctrl_m" class="eventNotifier">Ctrl+m</div><div id="_Ctrl_n" class="eventNotifier">Ctrl+n</div><div id="_Ctrl_o" class="eventNotifier">Ctrl+o</div><div id="_Ctrl_p" class="eventNotifier">Ctrl+p</div><div id
="_Ctrl_q" class="eventNotifier">Ctrl+q</div><div id="_Ctrl_r" class="eventNotifier">Ctrl+r</div><div id="_Ctrl_s" class="eventNotifier">Ctrl+s</div><div id="_Ctrl_t" class="eventNotifier">Ctrl+t</div><div id="_Ctrl_u" class=
"eventNotifier">Ctrl+u</div><div id="_Ctrl_v" class="eventNotifier">Ctrl+v</div><div id="_Ctrl_w" class="eventNotifier">Ctrl+w</div><div id="_Ctrl_x" class="eventNotifier">Ctrl+x</div><div id="_Ctrl_y" class="eventNotifier">
Ctrl+y</div><div id="_Ctrl_z" class="eventNotifier">Ctrl+z</div><div style="clear: both;"/><strong>Shift</strong><div id="_Shift_a" class="eventNotifier">Shift+a</div><div id="_Shift_b" class="eventNotifier">Shift+b</div><div 
id="_Shift_c" class="eventNotifier">Shift+c</div><div id="_Shift_d" class="eventNotifier">Shift+d</div><div id="_Shift_e" class="eventNotifier">Shift+e</div><div id="_Shift_f" class="eventNotifier">Shift+f</div><div id=
"_Shift_g" class="eventNotifier">Shift+g</div><div id="_Shift_h" class="eventNotifier">Shift+h</div><div id="_Shift_i" class="eventNotifier">Shift+i</div><div id="_Shift_j" class="eventNotifier">Shift+j</div><div id="_Shift_k" 
class="eventNotifier">Shift+k</div><div id="_Shift_l" class="eventNotifier">Shift+l</div><div id="_Shift_m" class="eventNotifier">Shift+m</div><div id="_Shift_n" class="eventNotifier">Shift+n</div><div id="_Shift_o" class=
"eventNotifier">Shift+o</div><div id="_Shift_p" class="eventNotifier">Shift+p</div><div id="_Shift_q" class="eventNotifier">Shift+q</div><div id="_Shift_r" class="eventNotifier">Shift+r</div><div id="_Shift_s" class=
"eventNotifier">Shift+s</div><div id="_Shift_t" class="eventNotifier">Shift+t</div><div id="_Shift_u" class="eventNotifier">Shift+u</div><div id="_Shift_v" class="eventNotifier">Shift+v</div><div id="_Shift_w" class=
"eventNotifier">Shift+w</div><div id="_Shift_x" class="eventNotifier">Shift+x</div><div id="_Shift_y" class="eventNotifier">Shift+y</div><div id="_Shift_z" class="eventNotifier">Shift+z</div><div style="clear: both;"/><strong>
Alt</strong><div id="_Alt_a" class="eventNotifier">Alt+a</div><div id="_Alt_b" class="eventNotifier">Alt+b</div><div id="_Alt_c" class="eventNotifier">Alt+c</div><div id="_Alt_d" class="eventNotifier">Alt+d</div><div id=
"_Alt_e" class="eventNotifier">Alt+e</div><div id="_Alt_f" class="eventNotifier">Alt+f</div><div id="_Alt_g" class="eventNotifier">Alt+g</div><div id="_Alt_h" class="eventNotifier">Alt+h</div><div id="_Alt_i" class=
"eventNotifier">Alt+i</div><div id="_Alt_j" class="eventNotifier">Alt+j</div><div id="_Alt_k" class="eventNotifier">Alt+k</div><div id="_Alt_l" class="eventNotifier">Alt+l</div><div id="_Alt_m" class="eventNotifier">Alt+m</div
><div id="_Alt_n" class="eventNotifier">Alt+n</div><div id="_Alt_o" class="eventNotifier">Alt+o</div><div id="_Alt_p" class="eventNotifier">Alt+p</div><div id="_Alt_q" class="eventNotifier">Alt+q</div><div id="_Alt_r" class=
"eventNotifier">Alt+r</div><div id="_Alt_s" class="eventNotifier">Alt+s</div><div id="_Alt_t" class="eventNotifier">Alt+t</div><div id="_Alt_u" class="eventNotifier">Alt+u</div><div id="_Alt_v" class="eventNotifier">Alt+v</div
><div id="_Alt_w" class="eventNotifier">Alt+w</div><div id="_Alt_x" class="eventNotifier">Alt+x</div><div id="_Alt_y" class="eventNotifier">Alt+y</div><div id="_Alt_z" class="eventNotifier">Alt+z</div><div style="clear: both;"
/><h2>Special Modifiers + Special Keys</h2><div style="clear: both;"/><strong>Ctrl</strong><div id="_Ctrl_esc" class="eventNotifier">Ctrl+esc</div><div id="_Ctrl_tab" class="eventNotifier">Ctrl+tab</div><div id="_Ctrl_space" 
class="eventNotifier">Ctrl+space</div><div id="_Ctrl_return" class="eventNotifier">Ctrl+return</div><div id="_Ctrl_backspace" class="eventNotifier">Ctrl+backspace</div><div id="_Ctrl_scroll" class="eventNotifier">Ctrl+scroll
</div><div id="_Ctrl_capslock" class="eventNotifier">Ctrl+capslock</div><div id="_Ctrl_numlock" class="eventNotifier">Ctrl+numlock</div><div id="_Ctrl_pause" class="eventNotifier">Ctrl+pause</div><div id="_Ctrl_insert" class=
"eventNotifier">Ctrl+insert</div><div id="_Ctrl_home" class="eventNotifier">Ctrl+home</div><div id="_Ctrl_del" class="eventNotifier">Ctrl+del</div><div id="_Ctrl_end" class="eventNotifier">Ctrl+end</div><div id="_Ctrl_pageup" 
class="eventNotifier">Ctrl+pageup</div><div id="_Ctrl_pagedown" class="eventNotifier">Ctrl+pagedown</div><div id="_Ctrl_left" class="eventNotifier">Ctrl+left</div><div id="_Ctrl_up" class="eventNotifier">Ctrl+up</div><div id=
"_Ctrl_right" class="eventNotifier">Ctrl+right</div><div id="_Ctrl_down" class="eventNotifier">Ctrl+down</div><div id="_Ctrl_f1" class="eventNotifier">Ctrl+f1</div><div id="_Ctrl_f2" class="eventNotifier">Ctrl+f2</div><div id=
"_Ctrl_f3" class="eventNotifier">Ctrl+f3</div><div id="_Ctrl_f4" class="eventNotifier">Ctrl+f4</div><div id="_Ctrl_f5" class="eventNotifier">Ctrl+f5</div><div id="_Ctrl_f6" class="eventNotifier">Ctrl+f6</div><div id="_Ctrl_f7" 
class="eventNotifier">Ctrl+f7</div><div id="_Ctrl_f8" class="eventNotifier">Ctrl+f8</div><div id="_Ctrl_f9" class="eventNotifier">Ctrl+f9</div><div id="_Ctrl_f10" class="eventNotifier">Ctrl+f10</div><div id="_Ctrl_f11" class=
"eventNotifier">Ctrl+f11</div><div id="_Ctrl_f12" class="eventNotifier">Ctrl+f12</div><div style="clear: both;"/><strong>Shift</strong><div id="_Shift_esc" class="eventNotifier">Shift+esc</div><div id="_Shift_tab" class=
"eventNotifier">Shift+tab</div><div id="_Shift_space" class="eventNotifier">Shift+space</div><div id="_Shift_return" class="eventNotifier">Shift+return</div><div id="_Shift_backspace" class="eventNotifier">Shift+backspace</div
><div id="_Shift_scroll" class="eventNotifier">Shift+scroll</div><div id="_Shift_capslock" class="eventNotifier">Shift+capslock</div><div id="_Shift_numlock" class="eventNotifier">Shift+numlock</div><div id="_Shift_pause" class
="eventNotifier">Shift+pause</div><div id="_Shift_insert" class="eventNotifier">Shift+insert</div><div id="_Shift_home" class="eventNotifier">Shift+home</div><div id="_Shift_del" class="eventNotifier">Shift+del</div><div id=
"_Shift_end" class="eventNotifier">Shift+end</div><div id="_Shift_pageup" class="eventNotifier">Shift+pageup</div><div id="_Shift_pagedown" class="eventNotifier">Shift+pagedown</div><div id="_Shift_left" class="eventNotifier">
Shift+left</div><div id="_Shift_up" class="eventNotifier">Shift+up</div><div id="_Shift_right" class="eventNotifier">Shift+right</div><div id="_Shift_down" class="eventNotifier">Shift+down</div><div id="_Shift_f1" class=
"eventNotifier">Shift+f1</div><div id="_Shift_f2" class="eventNotifier">Shift+f2</div><div id="_Shift_f3" class="eventNotifier">Shift+f3</div><div id="_Shift_f4" class="eventNotifier">Shift+f4</div><div id="_Shift_f5" class=
"eventNotifier">Shift+f5</div><div id="_Shift_f6" class="eventNotifier">Shift+f6</div><div id="_Shift_f7" class="eventNotifier">Shift+f7</div><div id="_Shift_f8" class="eventNotifier">Shift+f8</div><div id="_Shift_f9" class=
"eventNotifier">Shift+f9</div><div id="_Shift_f10" class="eventNotifier">Shift+f10</div><div id="_Shift_f11" class="eventNotifier">Shift+f11</div><div id="_Shift_f12" class="eventNotifier">Shift+f12</div><div style="clear: 
both;"/><strong>Alt</strong><div id="_Alt_esc" class="eventNotifier">Alt+esc</div><div id="_Alt_tab" class="eventNotifier">Alt+tab</div><div id="_Alt_space" class="eventNotifier">Alt+space</div><div id="_Alt_return" class=
"eventNotifier">Alt+return</div><div id="_Alt_backspace" class="eventNotifier">Alt+backspace</div><div id="_Alt_scroll" class="eventNotifier">Alt+scroll</div><div id="_Alt_capslock" class="eventNotifier">Alt+capslock</div><div 
id="_Alt_numlock" class="eventNotifier">Alt+numlock</div><div id="_Alt_pause" class="eventNotifier">Alt+pause</div><div id="_Alt_insert" class="eventNotifier">Alt+insert</div><div id="_Alt_home" class="eventNotifier">Alt+home
</div><div id="_Alt_del" class="eventNotifier">Alt+del</div><div id="_Alt_end" class="eventNotifier">Alt+end</div><div id="_Alt_pageup" class="eventNotifier">Alt+pageup</div><div id="_Alt_pagedown" class="eventNotifier">Alt+
pagedown</div><div id="_Alt_left" class="eventNotifier">Alt+left</div><div id="_Alt_up" class="eventNotifier">Alt+up</div><div id="_Alt_right" class="eventNotifier">Alt+right</div><div id="_Alt_down" class="eventNotifier">Alt+
down</div><div id="_Alt_f1" class="eventNotifier">Alt+f1</div><div id="_Alt_f2" class="eventNotifier">Alt+f2</div><div id="_Alt_f3" class="eventNotifier">Alt+f3</div><div id="_Alt_f4" class="eventNotifier">Alt+f4</div><div id=
"_Alt_f5" class="eventNotifier">Alt+f5</div><div id="_Alt_f6" class="eventNotifier">Alt+f6</div><div id="_Alt_f7" class="eventNotifier">Alt+f7</div><div id="_Alt_f8" class="eventNotifier">Alt+f8</div><div id="_Alt_f9" class=
"eventNotifier">Alt+f9</div><div id="_Alt_f10" class="eventNotifier">Alt+f10</div><div id="_Alt_f11" class="eventNotifier">Alt+f11</div><div id="_Alt_f12" class="eventNotifier">Alt+f12</div></div>



用戶評論
大牛,別默默的看了,快登錄幫我點評一下吧!:)      登錄 | 注冊


熱門標簽: 滾動切換 滾動條切換 滑動選項卡 滑動切換 選項卡切換 選項卡 切換 tab切換 頁面切換 選項卡插件 切換插件 滑動手風琴 滑動星星打分 其他 背景切換 大圖切換 鍵盤
?
×
×

注冊

官方QQ群

掃描上面二維碼加微信群

官方QQ群

jQuery/js討論群
群號:642649996
Css3+Html5討論群
群號:322131262

加群請備注:從官網了解到

湖北30选5开奖结果走势图表