会员
众包
新闻
博问
闪存
赞助商
HarmonyOS
Chat2DB
所有博客
当前博客
我的博客
我的园子
账号设置
会员中心
简洁模式
...
退出登录
注册
登录
Young
工作过程中记录的前端相关的问题。
博客园
首页
新随笔
联系
订阅
管理
上一页
1
2
3
4
5
6
7
8
···
18
下一页
2014年6月19日
在父页面和其iframe之间函数回调 父页面回调iframe里写的函数
摘要: // @shaoyang 父页面 window['mengBanLogin']={ mengBanArr : new Array(), mengBanLoginSuccess : function(){ console.log('mengban...
阅读全文
posted @ 2014-06-19 12:23 mabel_on_line
阅读(3871)
评论(0)
推荐(0)
2014年6月16日
jQuery :gt 选择器 jQuery :lt 选择器
摘要: 选择前 3 个之后的所有 元素:$("tr:gt(2)");选择前 2 个 元素:$("tr:lt(2)");
阅读全文
posted @ 2014-06-16 11:56 mabel_on_line
阅读(635)
评论(0)
推荐(0)
2014年6月12日
表单提交时判断
摘要: 换成:用$("#myBtn").click(function(){...//判断验证});表单提交js:function formSubmit(){if(flag=="1"){$("#form").submit();}else if(flag=="2"){$("#form").attr("actio...
阅读全文
posted @ 2014-06-12 18:53 mabel_on_line
阅读(513)
评论(0)
推荐(0)
弹出层背景常用的宽度和高度
摘要: var bgWidth = document.body.clientWidth + "px", bgHeight = document.body.clientHeight + "px",
阅读全文
posted @ 2014-06-12 11:10 mabel_on_line
阅读(468)
评论(0)
推荐(0)
2014年6月11日
jQuery判断元素是否显示 是否隐藏
摘要: var node=$('#id');第一种写法if(node.is(':hidden')){ //如果node是隐藏的则显示node元素,否则隐藏 node.show(); }else{ node.hide();}第二种写法if(!node.is(':visible')){ //如果node...
阅读全文
posted @ 2014-06-11 15:46 mabel_on_line
阅读(73275)
评论(0)
推荐(2)
jQuery中this 和 $(this)
摘要: var node = $('#id');node.click(function(){ this.css('display','block'); //报错 this是一个html元素,不是jquery对象,因此this不能调用jquery的css()方法 $(this).css(); ...
阅读全文
posted @ 2014-06-11 15:26 mabel_on_line
阅读(1661)
评论(0)
推荐(0)
如何编写好的jQuery代码
摘要: 本文就是自己看,如果您不小心进到了这里,请看源处,是这个作者翻译的:http://blog.sae.sina.com.cn/archives/4157讨论jQuery和javascript性能的文章并不罕见。然而,本文我计划总结一些速度方面的技巧和我本人的一些建议,来提升你的jQuery和javas...
阅读全文
posted @ 2014-06-11 11:04 mabel_on_line
阅读(248)
评论(0)
推荐(0)
2014年6月10日
设置 vadio 和checkbox是否选中
摘要: 1.js方案test2.jQuery方案$('#AgencyNew_fill_account').attr("checked", false);$('#AgencyNew_fill_account').attr("checked", true);
阅读全文
posted @ 2014-06-10 17:13 mabel_on_line
阅读(402)
评论(0)
推荐(0)
clientWidth offsetWidth scrollWidth
摘要: 网页可见区域宽: document.body.clientWidth;网页可见区域高: document.body.clientHeight;网页可见区域宽: document.body.offsetWidth(包括边线的宽);网页可见区域高: document.body.offsetHeight(...
阅读全文
posted @ 2014-06-10 14:57 mabel_on_line
阅读(266)
评论(0)
推荐(0)
数据类型
摘要: 1.定义变量的时候,需要初始化,这是一种习惯var box=null; //对象的初始化一般用nullvar box={ //以后再声明 age:10}var box=''; //创建一个字符串对象,一开始不知道赋值什么的时候,就创建为空字符串var box=0; //数值初始化,一般为0va...
阅读全文
posted @ 2014-06-10 11:01 mabel_on_line
阅读(192)
评论(0)
推荐(0)
上一页
1
2
3
4
5
6
7
8
···
18
下一页
公告