随笔分类 -  jQuery

摘要:<!DOCTYPE html><html><head><meta charset="utf-8" /><style> * {margin:0; padding:0; list-style: none; } .main { position: relative;} .clear { clear: bo 阅读全文
posted @ 2016-07-05 16:09 ifIhaveWings 阅读(258) 评论(0) 推荐(0)
摘要:<!DOCTYPE html><html><head><meta charset="utf-8" /><style> * {margin:0; padding:0; list-style: none; } .main { position: relative;} .clear { clear: bo 阅读全文
posted @ 2016-07-05 16:09 ifIhaveWings 阅读(388) 评论(0) 推荐(0)
摘要:function fn01() { $('selector').each(function(index) { if (index % 3 == 0) { $(this)........ } );} 只要该元素的ind... 阅读全文
posted @ 2015-12-16 14:16 ifIhaveWings 阅读(122) 评论(0) 推荐(0)
摘要:text() - 设置或返回所选元素的文本内容html() - 设置或返回所选元素的内容(包括 HTML 标记)val() - 设置或返回表单字段的值下面的例子演示如何通过 text()、html() 以及 val() 方法来设置内容:实例$("#btn1").click(function(){ ... 阅读全文
posted @ 2015-11-30 17:34 ifIhaveWings 阅读(234) 评论(0) 推荐(0)
摘要:width() 方法设置或返回元素的宽度(不包括内边距、边框或外边距)。 height() 方法设置或返回元素的高度(不包括内边距、边框或外边距)。 innerWidth() 方法返回元素的宽度(包括内边距)。 innerHeight() 方法返回元素的高度(包括内边距)。 oute... 阅读全文
posted @ 2015-11-30 17:05 ifIhaveWings 阅读(261) 评论(0) 推荐(0)