IE jquery mouseenter,mouseover超奇葩问题
做了个项目,结构很简单
- <div class="index-main" data-url="./img/index_default.jpg">
- <p class="main-bg" data-init="img"><img src="./img/index_default.jpg" alt="" /></p>
- <h1 class="index-logo">
- <a href="index.php"><img src="./img/index_logo.png" alt="RAMAD" /></a>
- </h1>
- <div class="index-cont">
- <ul>
- <li class="ramad" data-url="./img/index01.jpg">
- <strong class="tl"><a href="javascript:;"><span>RAMAD</span> 莱蒙达<em class="line"></em></a></strong>
- <div class="cont">
- <span class="line"></span>
- <a href="aboutus.php" data-url="./img/index03.jpg">RAMAD介绍</a>
- <a href="aboutus.php" data-url="./img/index02.jpg">RAMAD理念</a>
- </div>
- </li>
- <li data-url="./img/index04.jpg">
- <strong class="tl"><a href="javascript:;">品牌历史</a></strong>
- <div class="cont">
- <span class="line"></span>
- <a href="history.php" data-url="./img/index05.jpg">品牌历史</a>
- <a href="customize.php" data-url="./img/index06.jpg">定制历史</a>
- </div>
- </li>
- <li data-url="./img/index07.jpg">
- <strong class="tl"><a href="javascript:;">赏&析</a></strong>
- <div class="cont">
- <span class="line"></span>
- <a href="idea.php" data-url="./img/index09.jpg">析 · <span class="arial">STORY</span></a>
- <a href="idea.php" data-url="./img/index08.jpg">赏 · <span class="arial">ART</span></a>
- </div>
- </li>
- <li data-url="./img/index10.jpg">
- <strong class="tl"><a href="javascript:;">产品展示</a></strong>
- <div class="cont">
- <span class="line"></span>
- <a href="product.php" data-url="./img/index11.jpg">西服</a>
- <a href="product.php" data-url="./img/index13.jpg">衬衫</a>
- <a href="product.php" data-url="./img/index12.jpg">其他</a>
- </div>
- </li>
- <li data-url="./img/index16.jpg">
- <strong class="tl"><a href="javascript:;">服务体系</a></strong>
- <div class="cont">
- <span class="line"></span>
- <a href="idea.php" data-url="./img/index14.jpg">定制流程</a>
- <a href="idea.php" data-url="./img/index15.jpg">核心体系</a>
- </div>
- </li>
- </ul>
- </div>
- <div class="index-foot">
- <div class="cont">
- <p class="fl">浙ICP-88880000号 丨 <a href="#">集团网站入口</a> 丨 TEL:1512634984</p>
- <p class="fr"><a href="#">中文版</a> 丨 <a href="#">ENGLISH</a></p>
- </div>
- </div>
- </div>
- $(".index-cont li").mouseenter(function() {
- alert($(this).index());
- });
这里的mouseenter时灵时不灵,原因是.main-bg用的绝对定位,.index-cont相对定位覆盖在上面,IE在一个绝对定位元素里面没有内容, 没有背景的时候, 鼠标覆盖不到 .........解决方法加个透明的背景就解决了
IE jquery mouseenter,mouseover超奇葩问题的更多相关文章
- jquery中mouseover和mouseenter的区别
jquery中mouseover和mouseenter的区别 一.总结 一句话总结: 见名知意:enter(进入)和over(在上方)的意思好好思考一下 mouseover就是从子元素回到自己的时候也 ...
- jquery mouseenter()方法 语法
jquery mouseenter()方法 语法 作用:当鼠标指针穿过元素时,会发生 mouseenter 事件.该事件大多数时候会与 mouseleave 事件一起使用.mouseenter() 方 ...
- 一款由jquery实现的超炫的页面加载特效
今天为大家带来一款由jquery实现的超炫的页面加载特效.连续的几个页面分开特效.最后由三维的线条由远至近消失,然后由近至远出现.效果超级梦炫.一起看下效果图: 在线预览 源码下载 实现的代码. ...
- 基于jquery和svg超炫的网页动画
今天给大家分享一款基于jquery和svg超炫的网页动画.这款动画效果非常炫.下面还有重播.慢速.和反向动画按钮.效果非常漂亮.一起看下效果图: 在线预览 源码下载 实现的代码. html代码: ...
- jQuery关于mouseover和mouseenter的区别
原生的mouseenter是dom3级的事件,对于jQuery等一些框架已经实现了这个事件.但是它到底跟mouseover有什么区别? jQuery在实现这两个事件的时候,mouseover支持事件冒 ...
- jQuery事件--mouseover()、mouseout()、mouseenter()和mouseleave()
mouseover([[data],fn]) 概述 当鼠标指针位于元素上方时,会发生 mouseover 事件.该事件大多数时候会与 mouseout 事件一起使用 注释:与 mouseente ...
- jquery mouseout mouseover 多次执行
用jquery,mouseout,mouseover,随着鼠标移动,事件被触发了多次(冒泡),换成js onmouseover,onmouseout也是一样.最终的解决办法是,用jquery,mous ...
- jQuery因mouseover,mouseout冒泡产生的闪烁问题
由于浏览器的冒泡行为.造成如果在一个DIV元素上同时定义了mouseover,mouseout的时候,当鼠标移动到DIV中的child子元素的时候,就会同时执行了两个操作mouseover和mouse ...
- jQuery中mouseover和mouseout冒泡产生闪烁问题
问题:在jQuery中,对元素绑定mouseover和mouseout事件时,每次移入移出该元素和子元素时,都会触发事件,从而会出现闪动的现象. 原因:浏览器的冒泡行为. 解决方案: 使用mousee ...
随机推荐
- 十大流行Linux发行版
[2013年5月13日 51CTO外电头条]Linux是功能强大的常用操作系统之一,目前它在计算机操作系统领域的发展速度越来越快.它提供了出色的性能和速度.Linux用起来非常稳定而可靠.它还提供了几 ...
- [LOJ 1030] Discovering Gold
B - Discovering Gold Time Limit:2000MS Memory Limit:32768KB 64bit IO Format:%lld & %llu ...
- ↗☻【编写可维护的JavaScript #BOOK#】第8章 避免“空比较”
<!DOCTYPE html> <html lang="zh-CN"> <head> <meta charset="utf-8& ...
- apache开源项目--Sirona
Apache Sirona 为 Java 应用程序提供了一个简单但可扩展的监控解决方案. apache / sirona
- apache开源项目--ApacheDS
ApacheDS (Apache Directory Server)的核心是目录服务,可以保存数据,并对不同类型的数据进行搜索操作.协议的实现在目录服务器顶层工作,提供与数据存储.搜索和检索有关的 I ...
- 向Oracle数据库中插入数据出错:ORA-01036 无效的变量名或数据
向Oracle数据库中插入数据出错: 经过排查,因为Update数据时没有出错,所以OracleHelper没有问题: 看异常信息提示:无效的变量和数据,应该是SQL语句的问题,调试时所传的实例Use ...
- 在.net中用Connection对象数据源的架构信息
可得到数据库中的,表,视图,等信息 string strcon = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source = " + fi ...
- 【转】Linux(Ubuntu)下面SecureCRT 完全破解
仅供测试, 勿用作商业用途.首先要到vandyke网站下载一个securecrt, 需要注册.http://www.vandyke.com/download/securecrt/download.ht ...
- HDU 5690 All X 暴力循环节
分析:暴力找循环节就好了 #include <iostream> #include <cstdio> #include <cstdlib> #include < ...
- 发送复杂的HTTP GET请求并且取回响应。
设计思想: 创建一个HttpWebRequest类的实例,并通过GetReponse()方法取回响应的HTTP响应. 实例方案: string url="http://www.baidu.c ...