JS-jQuery:百科
| ylbtech-JS-jQuery:百科 |
| 1.返回顶部 |
- 中文名:极快瑞
- 外文名:jQuery
- 核心理念:write less,do more
- 发布时间:2006年1月
- 发布人:John Resig
- 发布地点:美国纽约
- 最新版本:jQuery 3.4.1
- 第一个版本:jQuery 1.0(2006年1月)
- 内部引入库:Sizzle.js
| 2.返回顶部 |
发展历程
|
1
2
3
4
5
6
7
|
Behaviour.register({ '#example li': function(e){ e.onclick = function(){ this.parentNode.removeChild(this); } }}); |
|
1
2
3
4
5
|
$('#example li').bind('click',function(){ this.parentNode.removeChild(this);}); 第二个例子是为不同的元素注册不同的事件: |
|
1
2
3
4
5
6
7
8
9
10
11
12
|
Behaviour.register({ 'b.someclass' : function(e){ e.onclick = function(){ alert(this.innerHTML); } }, '#someid u' : function(e){ e.onmouseover = function(){ this.innerHTML = "BLAH!"; } }}); |
|
1
2
3
4
5
6
|
$('b.someclass').bind('click',function(){ alert(this.innerHTML);});$('#someid u').bind('mouseover',function(){ this.innerHTML = 'BLAH!';}); |
|
1
2
3
4
5
6
7
8
9
10
11
12
|
Behaviour.register({ '#foo ol li': function(a) { a.title = "List Items!"; a.onclick = function(){ alert('Hello!'); }; }, '#foo ol li.tmp': function(a) { a.style.color = 'white'; }, '#foo ol li.tmp .foo': function(a) { a.style.background = 'red';}}); |
|
1
2
3
4
5
6
7
|
$('#foo ol li') .set('title','List Items!') .bind('click',function(){ alert('Hello!'); }) .select('.tmp') .style('color','white') .select('.foo') .style('background','red'); |
|
1
2
3
4
5
6
7
8
9
10
|
//1.4.2$("table").delegate("td", "hover", function(){ $(this).toggleClass("hover");});//1.3.2$("table").each(function(){ $("td", this).live("hover", function(){ $(this).toggleClass("hover"); });}); |
编程开发
语言特点
工作原理
语言基础
选择器
|
1
|
$("p") |
|
1
|
$("#test") |
|
1
|
$(".test") |
事件处理
|
1
|
$("p").click(); |
|
1
2
3
|
$("p").click(function(){ // 动作触发后执行的代码!!}); |
|
1
2
3
|
$("p").click(function(){ $(this).hide();}); |
|
1
2
3
|
$("p").dblclick(function(){ $(this).hide();}); |
|
1
2
3
|
$("#p1").mouseenter(function(){ alert("You entered p1!");}); |
|
1
2
3
|
$("#p1").mouseleave(function(){ alert("Bye! You now leave p1!");}); |
|
1
2
3
|
$("#p1").mousedown(function(){ alert("Mouse down over p1!");}); |
|
1
2
3
|
$("#p1").mouseup(function(){ alert("Mouse up over p1!");}); |
|
1
2
3
4
5
6
|
$("#p1").hover(function(){ alert("You entered p1!"); }, function(){ alert("Bye! You now leave p1!");}); |
|
1
2
3
|
$("input").focus(function(){ $(this).css("background-color","#cccccc");}); |
|
1
2
3
|
$("input").blur(function(){ $(this).css("background-color","#ffffff");}); |
技术应用
学习指南
语言评价
| 3.返回顶部 |
| 4.返回顶部 |
| 5.返回顶部 |
| 6.返回顶部 |
![]() |
作者:ylbtech 出处:http://ylbtech.cnblogs.com/ 本文版权归作者和博客园共有,欢迎转载,但未经作者同意必须保留此段声明,且在文章页面明显位置给出原文连接,否则保留追究法律责任的权利。 |
JS-jQuery:百科的更多相关文章
- js,jquery,css,html5特效
包含js,jquery,css,html5特效,源代码 本文地址:http://www.cnblogs.com/roucheng/p/texiao.html 2017新年快乐特效 jQuery最新最全 ...
- Js/Jquery获取iframe中的元素
转载: Js/Jquery获取iframe中的元素 - - ITeye技术网站http://java-my-life.iteye.com/blog/1275205 在web开发中,经常会用到ifram ...
- js/jquery/html前端开发常用到代码片段
1.IE条件注释 条件注释简介 IE中的条件注释(Conditional comments)对IE的版本和IE非IE有优秀的区分能力,是WEB设计中常用的hack方法.条件注释只能用于IE5以上,IE ...
- js jquery 页面加载初始化方法
js jquery 页面加载初始化方法 一.js页面加载初始化方法 // 1.在body里面写初始化方法. <body onload='init()'> </body> < ...
- js jquery 选择器总结
js jquery 选择器总结 一.原始JS选择器. id选择器:document.getElementById("test"); name选择器:document.getElem ...
- [JS]jQuery,javascript获得网页的高度和宽度
[JS]jQuery,javascript获得网页的高度和宽度网页可见区域宽: document.body.clientWidth 网页可见区域高: document.body.clientHeigh ...
- spring访问静态资源出错,No mapping found for HTTP request with URI xxx/resources/js/jquery.min.js...
问题:spring访问静态资源出错,No mapping found for HTTP request with URI xxx/resources/js/jquery.min.js... web.x ...
- js jquery中 的数据类型
任何一门语言, buguan 是动态的, 还是像C语言的, 都有严格的 类型 "概念的", 这个是由于 编译器和解释器要求的, 需要的. 所以在是使用像 js, jquey ,ph ...
- paip.提升效率--数据绑定到table原理和流程Angular js jquery实现
paip.提升效率--数据绑定到table原理和流程Angular js jquery实现 html #--keyword 1 #---原理和流程 1 #----jq实现的代码 1 #-----An ...
- JS Jquery去除数组重复元素
js jquery去除数组中的重复元素 第一种:$.unique() 第二种: for(var i = 0,len = totalArray_line.length;i < len;i++) { ...
随机推荐
- VS2010提示error TRK0002: Failed to execute command
转自VC错误:http://www.vcerror.com/?p=277 问题描述: windows8自动更新Microsoft .NET Framework 3.5和4.5.1安全更新程序,今天用V ...
- C++的指针偏移
假设一个类的定义如下:class Ob{public:Ob() : a(1), b(10) {}int a;private:int b; };
- SQL 交叉连接与内连接
交叉连接 ,没有任何限制方式的连接. 叫做交叉连接. 碰到一种SQL 的写法. select * from t1,t2 . 这其实是交叉连接 . t1 是三条 , t2 是两条. ...
- Master Reactor Manager Worker TaskWorker(Task)
1.Master进程 master进程为主进程,该进程会创建Manager进程和Reactor线程等工作进/线程 swoole的主进程,是个多线程的程序. 主进程内的回调函数: onStart onS ...
- Windows server 2016远程桌面登录和修改3389端口
- 【BZOJ2138】stone
题目 好厉害的题啊 这道题不难看成一个二分图模型,但是给人一种求最大匹配的感觉,这实在不是很好求的样子,于是自闭了 但是不妨这样来考虑,对于一个需求\(k_i\),我们求一个最大的\(x\leq k_ ...
- 下载Spring各个版本的jar包
网址:https://repo.spring.io/webapp/#/artifacts/browse/tree/General/libs-release-local/org/springframew ...
- Sql 将A表数据插入到B表
A表和B表字段不同 --insert into B(Name,PersonalId,Education,IsDel) select Name, PersonId as PersonalId, ( ca ...
- JQuery通过URL获取图片宽高
var img_url ='https://www.baidu.com/img/bd_logo1.png'; // 创建对象 var img = new Image(); // 改变图片的src im ...
- 2019-9-2-win10-uwp-隐私声明
title author date CreateTime categories win10 uwp 隐私声明 lindexi 2019-09-02 12:57:38 +0800 2018-2-13 1 ...
