常用的JQuery单击操作汇总
来源:互联网 发布:c语言多进程编程实例 编辑:程序博客网 时间:2024/06/09 18:08
1最好用的点击
$(document).on("click","#enlargeImgId",function(event){
var width = $(this).width();
if(width==100)
{
$(this).width(300);
$(this).height(300);
}
else
{
$(this).width(100);
$(this).height(100);
}
});
后边实际需要而定
2、点击
$("#enlargeImgId").click(function(){
var width = $(this).width();
if(width==100)
{
$(this).width(300);
$(this).height(300);
}
else
{
$(this).width(100);
$(this).height(100);
}
});
3绑定
$("#enlargeImgId").bind("click",function(){
var width = $(this).width();
if(width==100)
{
$(this).width(300);
$(this).height(300);
}
else
{
$(this).width(100);
$(this).height(100);
}
});
阅读全文
0 0
- 常用的JQuery单击操作汇总
- JQuery DOM 常用操作汇总
- jQuery操作表格(table)的常用方法、技巧汇总
- jQuery操作表格(table)的常用方法、技巧汇总
- 汇总常用的jQuery操作Table tr td方法
- 汇总常用的jQuery操作Table tr td方法
- jQuery操作表格(table)的常用方法、技巧汇总
- Jquery常用的方法汇总
- 常见的JQuery操作汇总
- jquery的常用操作
- Jquery的常用操作
- 常用的 Javascript 操作汇总
- 20170726 jQuery操作表格(table)的常用方法、技巧汇总
- JQuery DOM 的常用操作
- jquery常用的表单操作
- JQuery DOM 的常用操作
- Jquery 的一些常用操作
- jquery学习心得,常用的操作
- 学习一观察者模式(observer)
- 华为手机无法弹出Toast
- Redis连接命令
- set+ vector的详解及用法
- KVM网络性能调优终极版
- 常用的JQuery单击操作汇总
- hdu 1162 Eddy's picture 基础最小生成树★
- JS函数(一)
- 347. Top K Frequent Elements [leetcode]
- 如何提取mathematica方程的解,并用在后面的计算中
- Spring学习笔记: Repository实现(一)
- pip安装报错:is not a supported wheel on this platform
- 关于spring配置文件<context:property-placeholder>
- tocker笔记