search
HomeWeb Front-endJS TutorialSolution to the problem of mouseout triggered by mouse passing option in IE_javascript skills

The example in this article describes the solution to the problem of triggering mouseout when the mouse passes the option in IE. Share it with everyone for your reference. The specific analysis is as follows:

Function to be implemented:

There is a DIV. When the mouse passes over the DIV, it is fully expanded. When the mouse is removed, the DIV shrinks back. There is a select box inside the DIV;

A problem will occur in IE when operating select. When the mouse passes over the option, the DIV will shrink back, but this phenomenon does not occur in other browsers.

Solution:

In IE, when the mouse moves to option, the value of window.event.toElement is null, and in other browsers, the value is object;

When the mouse is moved directly out of the DIV, the value of window.event.toElement is object, as are other browsers;

To sum up, you can add the following code to mouseout to solve the problem:

if (window.event.toElement == null) return;

I hope this article will be helpful to everyone’s JavaScript programming design.

Statement
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
m590鼠标USB连接上用不了怎么办m590鼠标USB连接上用不了怎么办Mar 09, 2023 pm 03:18 PM

m590鼠标USB连接上用不了的解决办法:1、查看蓝牙设备,看是否识别为罗技优联连接器,然后下载Logitech Unifying优联软件,运行该软件;2、删除蓝牙设备,再添加蓝牙设备,重新连接m590即可。

mac鼠标滚轮相反怎么办mac鼠标滚轮相反怎么办Mar 16, 2023 pm 05:44 PM

mac鼠标滚轮相反的解决办法:1、打开mac电脑,点击屏幕的苹果标志,然后选择“系统偏好设置”;2、在“系统偏好设置”窗口中,选择“鼠标”;3、在“鼠标”窗口中,将“滚动方向:自然”前面的勾去掉即可。

电脑鼠标能动但点什么都没反应怎么办电脑鼠标能动但点什么都没反应怎么办Jul 06, 2023 pm 02:23 PM

电脑鼠标能动但点什么都没反应解决方法:1、检查鼠标连接,确认鼠标连接到电脑的USB接口上;2、重启电脑,断开鼠标连接,然后重新启动电脑并重新连接鼠标;3、更换鼠标电池或充电,如果使用的是无线鼠标,可能是因为鼠标电池电量低了,导致无法正常工作。

Win10鼠标dpi怎么调?Win10系统调节鼠标灵敏度实例教程Win10鼠标dpi怎么调?Win10系统调节鼠标灵敏度实例教程Jul 11, 2023 pm 03:13 PM

Win10鼠标dpi怎么调?鼠标dpi实际上简单点来说便是鼠标的敏感度。dpi值越高,鼠标灵敏度越高。许多好朋友全是应用Win10系统,要想了解如何修改鼠标dpi值,小编今日就告知各位朋友们怎么修改鼠标dpi值,期待对您有协助。Win10系统调节鼠标灵敏度实例教程1.鼠标右键点一下菜单栏,挑选设定,进到Windows设定页面,挑选开启机器设备;2.在左边的选择栏中转换到鼠标,随后在右边有关设定下挑选别的鼠标选择项;3.在鼠标特性对话框,将上边菜单栏转换到表针选择项,在下边挑选表针挪动速率来调节鼠

鼠标放在鼠标垫上为什么更灵敏鼠标放在鼠标垫上为什么更灵敏Nov 14, 2022 pm 02:21 PM

因为鼠标垫能辅助定位。鼠标垫给鼠标的定位和移动提供了良好的表面支撑,相比于直接放置在一般表面上,更能强化鼠标的可用性和实用性;且鼠标垫可以有效地降低鼠标底部碎片、灰尘的聚集,从而减少鼠标使用过程中跳帧的现象,有效增强鼠标在使用时的精确性,减少各种外部因素对鼠标的影响。

Win10鼠标在左上角拉不回来怎么办Win10鼠标在左上角拉不回来怎么办Feb 24, 2023 am 10:15 AM

Win10鼠标在左上角拉不回来的解决办法:1、确认鼠标是否异常,可以更换另一个鼠标;2、确认是否触屏导致,可以重新安装触屏驱动;3、确认是否软件设置导致,可以将其卸载;4、确认是否病毒木马导致,进行杀毒即可。

鼠标不灵敏是什么原因鼠标不灵敏是什么原因Mar 21, 2023 pm 04:30 PM

鼠标不灵敏可能是鼠标设置问题或硬件问题导致的,其解决办法:1、点击windows图标,选择控制面板;2、点击“硬件和声音”选项,进入鼠标属性界面,然后调节一下鼠标双击的速度,增加鼠标灵敏度;3、更换鼠标。

Internet Explorer 打开 Edge:如何停止 MS Edge 重定向Internet Explorer 打开 Edge:如何停止 MS Edge 重定向Apr 14, 2023 pm 06:13 PM

长期以来,InternetExplorer的失宠一直不是秘密,但随着Windows11的到来,现实开始了。Edge将来不再有时取代IE,它现在是微软最新操作系统中的默认浏览器。目前,您仍然可以在Windows11中启用InternetExplorer。但是,IE11(最新版本)已经有了一个正式的退役日期,即2022年6月15日,时间在流逝。考虑到这一点,您可能已经注意到InternetExplorer有时会打开Edge,而您可能不喜欢它。那么为什么会这样呢?在

See all articles

Hot AI Tools

Undresser.AI Undress

Undresser.AI Undress

AI-powered app for creating realistic nude photos

AI Clothes Remover

AI Clothes Remover

Online AI tool for removing clothes from photos.

Undress AI Tool

Undress AI Tool

Undress images for free

Clothoff.io

Clothoff.io

AI clothes remover

AI Hentai Generator

AI Hentai Generator

Generate AI Hentai for free.

Hot Article

Repo: How To Revive Teammates
1 months agoBy尊渡假赌尊渡假赌尊渡假赌
R.E.P.O. Energy Crystals Explained and What They Do (Yellow Crystal)
2 weeks agoBy尊渡假赌尊渡假赌尊渡假赌
Hello Kitty Island Adventure: How To Get Giant Seeds
1 months agoBy尊渡假赌尊渡假赌尊渡假赌

Hot Tools

Atom editor mac version download

Atom editor mac version download

The most popular open source editor

mPDF

mPDF

mPDF is a PHP library that can generate PDF files from UTF-8 encoded HTML. The original author, Ian Back, wrote mPDF to output PDF files "on the fly" from his website and handle different languages. It is slower than original scripts like HTML2FPDF and produces larger files when using Unicode fonts, but supports CSS styles etc. and has a lot of enhancements. Supports almost all languages, including RTL (Arabic and Hebrew) and CJK (Chinese, Japanese and Korean). Supports nested block-level elements (such as P, DIV),

SublimeText3 Linux new version

SublimeText3 Linux new version

SublimeText3 Linux latest version

VSCode Windows 64-bit Download

VSCode Windows 64-bit Download

A free and powerful IDE editor launched by Microsoft

ZendStudio 13.5.1 Mac

ZendStudio 13.5.1 Mac

Powerful PHP integrated development environment