懶就要懶到底——鼠標自動點擊(含時間判斷)
更新時間:2007年02月20日 00:00:00 作者:
其實老早之前就已經(jīng)做完了,這次稍微改進一下
瀏覽地址:http://www.healdream.com/upload/html/autoclick.html
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<title>無標題文檔</title>
<script src="yahoo.js" type="text/javascript"></script>
<script src="event.js" type="text/javascript"></script>
</head>
<body>
<p><a >鼠標放在這個鏈接上1.5秒以上,將進入藍色理想網(wǎng)站,當然不到1.5秒就沒有效果</a></p>
<p><a >同理移到這里將進入我的blog</a></p>
<script type="text/javascript">
var links=document.getElementsByTagName("a");
function return_obj(){
return source;
}
function auto_click(str){
window.location=str;
}
function mouseover_func(e){
source=event.srcElement;
start=setTimeout("auto_click('"+source+"')",1500);
}
function mouseout_func(e){
clearInterval(start);
}
YAHOO.util.Event.addListener(links,"mouseover",mouseover_func);
YAHOO.util.Event.addListener(links,"mouseout",mouseout_func);
</script>
</body>
</html>
瀏覽地址:http://www.healdream.com/upload/html/autoclick.html
復(fù)制代碼 代碼如下:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<title>無標題文檔</title>
<script src="yahoo.js" type="text/javascript"></script>
<script src="event.js" type="text/javascript"></script>
</head>
<body>
<p><a >鼠標放在這個鏈接上1.5秒以上,將進入藍色理想網(wǎng)站,當然不到1.5秒就沒有效果</a></p>
<p><a >同理移到這里將進入我的blog</a></p>
<script type="text/javascript">
var links=document.getElementsByTagName("a");
function return_obj(){
return source;
}
function auto_click(str){
window.location=str;
}
function mouseover_func(e){
source=event.srcElement;
start=setTimeout("auto_click('"+source+"')",1500);
}
function mouseout_func(e){
clearInterval(start);
}
YAHOO.util.Event.addListener(links,"mouseover",mouseover_func);
YAHOO.util.Event.addListener(links,"mouseout",mouseout_func);
</script>
</body>
</html>
相關(guān)文章
將字符串轉(zhuǎn)換成gb2312或者utf-8編碼的參數(shù)(js版)
直接在url中傳遞中文參數(shù)時,讀到的中文都是亂碼,那么我們應(yīng)該怎么將這些參數(shù)轉(zhuǎn)換呢,接下來與大家分享下將字符串轉(zhuǎn)換成utf-8或者gb2312編碼的參數(shù)的技巧2013-04-04
uniapp中scroll-view基礎(chǔ)用法示例代碼
我們在項目中往往都能遇到實現(xiàn)左右滑動跟上下滑動的需求,下面這篇文章主要給大家介紹了關(guān)于uniapp中scroll-view基礎(chǔ)用法的相關(guān)資料,文中通過實例代碼介紹的非常詳細,需要的朋友可以參考下2022-11-11
js HTML5 Ajax實現(xiàn)文件上傳進度條功能
這篇文章主要介紹了javascript實現(xiàn)文件上傳進度條功能的相關(guān)資料啊,感興趣的朋友可以參考一下2016-02-02

