懶得寫兼容,用jquery寫的話,
$(document).mousedown(function(e){
varclickKey=e.which==1?"左鍵":e.which==2?"中鍵":"右鍵";
alert("你點擊了鼠標"+clickKey+"!X坐標:"+e.pageX+",Y坐標:"+e.pageY);
});
懶得寫兼容,用jquery寫的話,
$(document).mousedown(function(e){
varclickKey=e.which==1?"左鍵":e.which==2?"中鍵":"右鍵";
alert("你點擊了鼠標"+clickKey+"!X坐標:"+e.pageX+",Y坐標:"+e.pageY);
});