惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

L
LINUX DO - 热门话题
Stack Overflow Blog
Stack Overflow Blog
B
Blog
WordPress大学
WordPress大学
Project Zero
Project Zero
P
Palo Alto Networks Blog
阮一峰的网络日志
阮一峰的网络日志
博客园 - 司徒正美
有赞技术团队
有赞技术团队
S
SegmentFault 最新的问题
freeCodeCamp Programming Tutorials: Python, JavaScript, Git & More
小众软件
小众软件
T
Tailwind CSS Blog
Forbes - Security
Forbes - Security
F
Full Disclosure
SecWiki News
SecWiki News
钛媒体:引领未来商业与生活新知
钛媒体:引领未来商业与生活新知
Hacker News: Ask HN
Hacker News: Ask HN
C
Check Point Blog
Microsoft Security Blog
Microsoft Security Blog
Threat Intelligence Blog | Flashpoint
Threat Intelligence Blog | Flashpoint
F
Fortinet All Blogs
Cisco Talos Blog
Cisco Talos Blog
G
Google Developers Blog
J
Java Code Geeks
Google DeepMind News
Google DeepMind News
人人都是产品经理
人人都是产品经理
CTFtime.org: upcoming CTF events
CTFtime.org: upcoming CTF events
Recorded Future
Recorded Future
O
OpenAI News
Spread Privacy
Spread Privacy
MongoDB | Blog
MongoDB | Blog
H
Hackread – Cybersecurity News, Data Breaches, AI and More
C
Cybersecurity and Infrastructure Security Agency CISA
S
Securelist
V
Vulnerabilities – Threatpost
Y
Y Combinator Blog
IT之家
IT之家
U
Unit 42
腾讯CDC
S
Security Affairs
C
Cisco Blogs
Schneier on Security
Schneier on Security
The Last Watchdog
The Last Watchdog
B
Blog RSS Feed
宝玉的分享
宝玉的分享
cs.AI updates on arXiv.org
cs.AI updates on arXiv.org
S
Security @ Cisco Blogs
Cyberwarzone
Cyberwarzone
T
The Blog of Author Tim Ferriss

博客园 - 古代

linux下关于重命名卷标 wget header参数使用。 - 古代 - 博客园 奔波尔霸温瑞安 方娥真〈月台〉析论 入凡尘十二年的方娥真 python 进程通信测试代码(程序A,程序B) parse_url 和再pathinfo,what you'll get - 古代 autopos php转换拼音,全。 RPM 安装mod_encoding,linux下apache支持中文名 自动杀死pps的后台进程 js表达式转义 - 古代 - 博客园 批量jstest get_top_dom($dom); - 古代 - 博客园 rm大量文件 Read-only file system处理记录 通过PHP获取生僻字的汉语拼音[转] 唉,这个备案,头疼. 神奇的js代码,图片全都飞起来了
模拟兼容onmouseleave,onmouseenter - 古代 - 博客园
古代 · 2010-08-25 · via 博客园 - 古代

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML>
 <HEAD>
  <TITLE> 模拟兼容onmouseleave,onmouseenter </TITLE>
  <META NAME="Generator" CONTENT="EditPlus">
  <META NAME="Author" CONTENT="">
  <META NAME="Keywords" CONTENT="">
  <META NAME="Description" CONTENT="">
 </HEAD>

 <BODY>
  <style>
h2{BORDER-top:5px solid black;}
</style>
<script>
function isMouseLeaveOrEnter(e, handler) {    
    if (e.type != 'mouseout' && e.type != 'mouseover') return false;    
    var reltg = e.relatedTarget ? e.relatedTarget : e.type == 'mouseout' ? e.toElement : e.fromElement;    
    while (reltg && reltg != handler)    
        reltg = reltg.parentNode;    
    return (reltg != handler);    
}
</script>

<h2>onmouseout onmouseover</h2><br> 
<div style="border: 1px solid black; width: 350px;"
onmouseout="var out = document.getElementById('out'); out.value = parseInt(out.value) + 1;"
onmouseover="var over = document.getElementById('over'); over.value = parseInt(over.value) + 1;"> 
    Try moving the mouse in and out of this div  
    <div style="background: #efe; margin: 20px; width: 160px; border: 5px solid black;">and the nested div</div> 
</div> 
<p> 
    mouseovers <input id="over" value="0"> 
    mouseouts <input id="out" value="0"><br> 
</p> 

<h2>兼容的 onmouseleave onmouseenter</h2><br> 
<div style="border: 1px solid black; width: 350px;"
onmouseout="var leave = document.getElementById('leave'); if (isMouseLeaveOrEnter(event, this)) leave.value = parseInt(leave.value) + 1;"
onmouseover="var enter = document.getElementById('enter'); if (isMouseLeaveOrEnter(event, this)) enter.value = parseInt(enter.value) + 1;"
>
    Try moving the mouse in and out of this div  
<div style="background: #efe; margin: 20px; width: 160px; border: 5px solid black;">and the nested div</div> 
</div>


<p> 
    mouseenters <input id="enter" value="0"> 
    mouseleaves <input id="leave" value="0"><br> 
</p>


<h2>仅IE onmouseleave onmouseenter</h2><br> 
<div style="border: 1px solid black; width: 350px;"
onmouseleave="var leave = document.getElementById('ieleave'); leave.value = parseInt(ieleave.value) + 1;"
onmouseenter="var enter = document.getElementById('ieenter'); enter.value = parseInt(ieenter.value) + 1;"> 
    Try moving the mouse in and out of this div  
    <div style="background: #efe; margin: 20px; width: 160px; border: 5px solid black;">and the nested div</div> 
</div>

<p> 
   only ie mouseenters <input id="ieenter" value="0"> 
   only ie mouseleaves <input id="ieleave" value="0"><br> 
</p>
 </BODY>
</HTML>