新手求救:firefox里怎么获取shift和ctrl键? function xxxx(){if(window.event.Keycode==16 ){ 要执行的语句块。}} 解决方案 » 免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货 <script>document.onkeydown=function(event){ if (event.which==16) alert('shift') if (event.which==17) alert('ctrl')}</script> 怎么会不起作用? 是你没用对吧<script>document.onkeydown=function(event){if (event.shiftKey) alert('shift')if (event.ctrlKey) alert('ctrl')}</script> FF中是没有event.ctrlKey 和event.shiftlKey,用前面几位的方法就好!! firefox里的event对象和IE里的event使用方法不一样 FF中是没有event.ctrlKey 和event.shiftlKey,用前面几位的方法就好!!谁说没有? 请你试过代码后再下结论! 那个jquery富文本编辑器最好用网上资源多?(用在JSP) 我查询后或者保存后,在查询/保存进行时候 想页面变灰~! 急!急!急!高手请进!如何取得map里的area? checkbox属性问题 javascript 在表格中插入一列 如何确定window.open新打开的页面链拉是正确的? 用vml画的polyLine 如何实现拖动 关于表格分页打印的问题 加了return效果一样 请教:表格tr里的连接点击后tr的背景变为红色,当在tr里点两下鼠标后红色消失 用javascript腳本改變文本框的背景顏色 confirm,无论选择“是”还是“否”都要运行以下的程序。
document.onkeydown=function(event){
if (event.which==16) alert('shift')
if (event.which==17) alert('ctrl')
}
</script>
<script>
document.onkeydown=function(event){
if (event.shiftKey) alert('shift')
if (event.ctrlKey) alert('ctrl')
}
</script>