博客
关于我
强烈建议你试试无所不能的chatGPT,快点击我
jquery双击修改_jQuery双击
阅读量:2531 次
发布时间:2019-05-11

本文共 1498 字,大约阅读时间需要 4 分钟。

jquery双击修改

jQuery dblclick() function fires when an HTML element is double clicked. This method will attach an event handler to the double click event. We can do desired manipulations on the selected HTML element using the jQuery double click event handler.

双击HTML元素时,将触发jQuery dblclick()函数。 此方法会将事件处理程序附加到双击事件。 我们可以使用jQuery双击事件处理程序对选定HTML元素进行所需的操作。

jQuery双击 (jQuery double click)

jQuery double click event syntax:

jQuery双击事件语法:

  • dblclick()

    dblclick()

In this, dblclick() method is used without an argument.

在这种情况下,使用dblclick()方法时不带参数。

  • dblclick(handler)

    dblclick(处理程序)

The handler could be any function that is executed each time the double click event is fired.

该处理程序可以是每次触发双击事件时执行的任何函数。

jQuery双击示例 (jQuery Double Click Example)

Following example demonstrates the use of jQuery dblclick() event method.

以下示例演示了jQuery dblclick()事件方法的使用。

jQuery Double Click 
JournalDev

In this example, you can see that dblclick() method is triggered when you double click on the <div> element.

在此示例中,您可以看到双击<div>元素时触发了dblclick()方法。

In this method, we pass a handler to change the background color of the <div> element.

在此方法中,我们传递了一个处理程序来更改<div>元素的背景颜色。

The toggleClass() method toggle between the two CSS class defined in the above code. The toggleClass() method executes each time when we double click on the element.

toggleClass()方法在上述代码中定义的两个CSS类之间切换。 每次双击元素时,都会执行toggleClass()方法。

You can see above jQuery example in action by visiting below URL.

您可以通过访问下面的URL来查看上面的jQuery示例的运行情况。

()

翻译自:

jquery双击修改

转载地址:http://hdlzd.baihongyu.com/

你可能感兴趣的文章
迷宫实现
查看>>
【字符编码】Java字符编码详细解答及问题探讨
查看>>
学习操作系统导图
查看>>
在线的JSON formate工具
查看>>
winform非常实用的程序退出方法!!!!!(转自博客园)
查看>>
xml解析
查看>>
centos安装vim
查看>>
linux工作调度(计划任务)
查看>>
hdu--1698 Just a Hook(线段树+区间更新+懒惰标记)
查看>>
Python学习笔记-EXCEL操作
查看>>
二月二——头牙诗词
查看>>
《吴忠与富平》之四:汉三水属国(北地属国、安定属国)
查看>>
丁酉立秋喜逢风雨
查看>>
vim删除#开头的行和正则表达式笔记
查看>>
python3 提成计算
查看>>
VBA赋值给指定单元格
查看>>
抽象类和接口总结回顾
查看>>
【语言处理与Python】5.3使用Python字典映射词及其属性
查看>>
设备信息
查看>>
Android Volley框架的使用(三)
查看>>