[转]JS中判断鼠标按键判断
JS中判断鼠标按键的问题。 
IE 
左键是 window.event.button = 1 
右键是 window.event.button = 2
中键是 window.event.button = 4
没有按键动作window.event.button = 0
Firefox 
左键是 event.button = 0 
右键是 event.button = 2
中键是 event.button = 1 
没有按键动作 event.button = 0
Opera 7.23/7.54
鼠标左键是 window.event.button = 1
没有按键动作 window.event.button = 1 
右键和中键无法获取 
Opera 7.60/8.0
鼠标左键是 window.event.button = 0
没有按键动作 window.event.button = 0
右键和中键无法获取 
另外:屏蔽右键的是window.event.button = 3
 
                     
                    
                 
                    
                
 
 
                
            
         
         浙公网安备 33010602011771号
浙公网安备 33010602011771号