- 浏览: 1158926 次
- 性别:
- 来自: 北京
-
文章分类
- 全部博客 (411)
- Java Foundation (41)
- AI/机器学习/数据挖掘/模式识别/自然语言处理/信息检索 (2)
- 云计算/NoSQL/数据分析 (11)
- Linux (13)
- Open Source (12)
- J2EE (52)
- Data Structures (4)
- other (10)
- Dev Error (41)
- Ajax/JS/JSP/HTML5 (47)
- Oracle (68)
- FLEX (19)
- Tools (19)
- 设计模式 (4)
- Database (12)
- SQL Server (9)
- 例子程序 (4)
- mysql (2)
- Web Services (4)
- 面试 (8)
- 嵌入式/移动开发 (18)
- 软件工程/UML (15)
- C/C++ (7)
- 架构Architecture/分布式Distributed (1)
最新评论
-
a535114641:
LZ你好, 用了这个方法后子页面里的JS方法就全不能用了呀
页面局部刷新的两种方式:form+iframe 和 ajax -
di1984HIT:
学习了,真不错,做个记号啊
Machine Learning -
赵师傅临死前:
我一台老机器,myeclipse9 + FB3.5 可以正常使 ...
myeclipse 10 安装 flash builder 4.6 -
Wu_Jiang:
触发时间在将来的某个时间 但是第一次触发的时间超出了失效时间, ...
Based on configured schedule, the given trigger will never fire. -
cylove007:
找了好久,顶你
Editable Select 可编辑select
JQuery速查表
http://www.gbsou.com/jquery-fact-sheet
http://docs.jquery.com/Main_Page
http://api.jquery.com/
http://visualjquery.com/
http://interface.eyecon.ro/
http://tablesorter.com/docs/
jquery min lite pack各版本的说明:
jquery min lite pack各版本的说明:
jquery.js 全功能未压缩 开发者使用
jquery.lite.js [lite英文是精简版 未压缩 将注释去掉]
jquery.min.js [min 英文最小版 精简版的压缩]
jquery.pack.js [全功能有压缩,]
pack压缩表示:浏览器及服务器端支持gzip 这样下载速度会很快.
jQuery对象和DOM对象的相互转换:
http://www.cnblogs.com/z-yy/archive/2012/07/17/2594963.html
http://www.cnblogs.com/ycbk/archive/2011/02/28/1967242.html
jquery的$("#formId").validate()里rules所指定的为element元素的name属性。
jQuery Selectors:
http://api.jquery.com/category/selectors/
为什么使用
$("#id")是 ID Selector:http://api.jquery.com/id-selector/
$(".myClass")是Class Selector:http://api.jquery.com/class-selector/
所以,当你使用 $("#fidsTextRefChannel.textFull") 时,jquery会认为You are trying to access the #fidsTextRefChannel with a class textFull。
解决办法:
一 使用双反斜杠对id中的dot做转义:
#(hash) .(dot) 外其他常用的选择器:
空格(blank) : Descendant Selector http://api.jquery.com/descendant-selector/
Help understanding JQuery Attribute Equals Selector:
http://stackoverflow.com/questions/3814966/help-understanding-jquery-attribute-equals-selector
$(document).ready 和 $(window).load 的区别:
Daily Tip : Difference between $(document).ready and $(window).load in jQuery:
http://web.enavu.com/daily-tip/daily-tip-difference-between-document-ready-and-window-load-in-jquery/
$(document).ready vs. $(window).load:
http://4loc.wordpress.com/2009/04/28/documentready-vs-windowload/
jQuery Validation Plugin:
http://stackoverflow.com/questions/4936221/jquery-validate-plugin-on-div
因为jquery的validation只能针对form,那对分组验证(即页面需要一步一步点击“下一步”,最后做提交)该怎么做那?一种解决思路如下:
http://www.cnblogs.com/wangjq/archive/2011/03/13/1983024.html
或者:(待以后细看补充 ; search key:jquery individual validate)
http://stackoverflow.com/questions/1495919/is-there-a-way-to-validate-individual-fields-in-jquery-not-the-whole-form
http://stackoverflow.com/questions/7429349/using-jquery-how-do-i-validate-individual-elements-and-show-the-relevant-error-m
jQuery学习之:Validation表单验证插件:
http://polaris.blog.51cto.com/1146394/258781
客户端验证的极品--jQuery.validator:
http://www.iteye.com/topic/255168
jquery.validate的用法(自定义方法验证,服务端验证):
http://hi.baidu.com/lxylxy888666/blog/item/ee96ab7b0c26f1f90ad18724.html
editable select list, plugin for jQuery:
http://coffeescripter.com/code/editable-select/
下列代码:
在IE下,radio的onchange事件在radio change时并没有被触发!而是在焦点移至页面其他域后才触发!这是IE的问题。解决办法是在jquery的ready方法中加上下列代码:
http://norman.walsh.name/2009/03/24/jQueryIE
http://blog.csdn.net/borishuai/archive/2009/12/08/4967696.aspx
http://www.gbsou.com/jquery-fact-sheet
http://docs.jquery.com/Main_Page
http://api.jquery.com/
http://visualjquery.com/
http://interface.eyecon.ro/
http://tablesorter.com/docs/
jquery min lite pack各版本的说明:
引用
jquery min lite pack各版本的说明:
jquery.js 全功能未压缩 开发者使用
jquery.lite.js [lite英文是精简版 未压缩 将注释去掉]
jquery.min.js [min 英文最小版 精简版的压缩]
jquery.pack.js [全功能有压缩,]
pack压缩表示:浏览器及服务器端支持gzip 这样下载速度会很快.
jQuery对象和DOM对象的相互转换:
http://www.cnblogs.com/z-yy/archive/2012/07/17/2594963.html
http://www.cnblogs.com/ycbk/archive/2011/02/28/1967242.html
jquery的$("#formId").validate()里rules所指定的为element元素的name属性。
jQuery Selectors:
http://api.jquery.com/category/selectors/
引用
If you wish to use any of the meta-characters ( such as !"#$%&'()*+,./:;<=>?@[\]^`{|}~ ) as a literal part of a name, you must escape the character with two backslashes: \\. For example, if you have an element with id="foo.bar", you can use the selector $("#foo\\.bar").
页面有如下element:<textarea name="fidsTextRefChannel.textFull" id="fidsTextRefChannel.textFull" rows="7" style="width:100%"></textarea>
为什么使用
$("#fidsTextRefChannel.textFull")时得不到该element?这与jquery的选择器Selector有关:
$("#id")是 ID Selector:http://api.jquery.com/id-selector/
$(".myClass")是Class Selector:http://api.jquery.com/class-selector/
所以,当你使用 $("#fidsTextRefChannel.textFull") 时,jquery会认为You are trying to access the #fidsTextRefChannel with a class textFull。
解决办法:
一 使用双反斜杠对id中的dot做转义:
$("#fidsTextRefChannel\\.textFull")二 使用Attribute Equals Selector:
$("textarea[id='fidsTextRefChannel.textFull']")
#(hash) .(dot) 外其他常用的选择器:
空格(blank) : Descendant Selector http://api.jquery.com/descendant-selector/
Help understanding JQuery Attribute Equals Selector:
http://stackoverflow.com/questions/3814966/help-understanding-jquery-attribute-equals-selector
引用
This selector:
$('#myid .two td[role=foo]')means: find the element with ID "myid". From it find all descendants with a class of "two". From those elements find all descendants <td> elements that have a role attribute with a value of "foo".
$(document).ready 和 $(window).load 的区别:
Daily Tip : Difference between $(document).ready and $(window).load in jQuery:
http://web.enavu.com/daily-tip/daily-tip-difference-between-document-ready-and-window-load-in-jquery/
$(document).ready vs. $(window).load:
http://4loc.wordpress.com/2009/04/28/documentready-vs-windowload/
jQuery Validation Plugin:
http://stackoverflow.com/questions/4936221/jquery-validate-plugin-on-div
引用
The validation plugin is (currently) designed to work on a <form>, and only on a <form>.
因为jquery的validation只能针对form,那对分组验证(即页面需要一步一步点击“下一步”,最后做提交)该怎么做那?一种解决思路如下:
http://www.cnblogs.com/wangjq/archive/2011/03/13/1983024.html
或者:(待以后细看补充 ; search key:jquery individual validate)
http://stackoverflow.com/questions/1495919/is-there-a-way-to-validate-individual-fields-in-jquery-not-the-whole-form
http://stackoverflow.com/questions/7429349/using-jquery-how-do-i-validate-individual-elements-and-show-the-relevant-error-m
jQuery学习之:Validation表单验证插件:
http://polaris.blog.51cto.com/1146394/258781
客户端验证的极品--jQuery.validator:
http://www.iteye.com/topic/255168
引用
jquery内置的maxlength验证的是输入的字符的长度。可以用这个来验证输入域的字节长度:
// 中文字两个字节 jQuery.validator.addMethod("byteRangeLength", function(value, element, param) { var length = value.length; for(var i = 0; i < value.length; i++){ if(value.charCodeAt(i) > 127){ length++; } } return this.optional(element) || ( length >= param[0] && length <= param[1] ); }, "请确保输入的值在{0}-{1}个字节之间(一个中文字算2个字节)");
jquery.validate的用法(自定义方法验证,服务端验证):
http://hi.baidu.com/lxylxy888666/blog/item/ee96ab7b0c26f1f90ad18724.html
editable select list, plugin for jQuery:
http://coffeescripter.com/code/editable-select/
下列代码:
$(document).ready(function() { $("input[name='fidsRuleParameter.type']").change(function() { //alert($(this).val()); if($(this).val()=="I") { $("#intValueUnitSpan").text("<s:text name='parameter.form.intValueUnit'/>"); } else { $("#intValueUnitSpan").text(""); } }); });
<td width="85%" align="left"> <input type="text" name="fidsRuleParameter.value" id="value" value="<s:property value="fidsRuleParameter.value"/>" class="intValueClass"/> <span id="intValueUnitSpan"><s:if test='%{#request.fidsRuleParameter.type=="I"}'><s:text name='parameter.form.intValueUnit'/></s:if></span> </td> <tr bgcolor="#FFFFFF"> <td width="15%" align="right"><label for="stationCode"><s:text name='parameter.form.type'/>: </label></td> <td width="85%" align="left"> <s:radio id="fidsRuleParameter.type" name="fidsRuleParameter.type" theme="simple" list="#{'I':getText('parameter.grid.renderer.type.I'), 'S':getText('parameter.grid.renderer.type.S')}"/> </td> </tr>
在IE下,radio的onchange事件在radio change时并没有被触发!而是在焦点移至页面其他域后才触发!这是IE的问题。解决办法是在jquery的ready方法中加上下列代码:
/** fix that problem: If you click on a radio button, IE seems to wait with firing the change event until you leave the button **/ $(function () { if ($.browser.msie) { $('input:radio').click(function () { this.blur(); this.focus(); }); } });相关链接:
http://norman.walsh.name/2009/03/24/jQueryIE
引用
If you click on a radio button, IE seems to wait with firing the change event until you leave the button, which is consistent with the behavior on other input fields (like text), but kinda unintuitive. The following piece of code fixes this behavior for me:
在IE中关于Radio和Checkbox在JQuery中的change事件的立即触发:
$(function () { if ($.browser.msie) { $('input:radio').click(function () { this.blur(); this.focus(); }); } });
http://blog.csdn.net/borishuai/archive/2009/12/08/4967696.aspx
发表评论
-
页面嵌入声音
2011-06-27 20:17 1258几个选择: embed标签 bgsound标签 objec ... -
DHTMLX
2011-05-13 09:53 2395通过 Access IFRAME Content 实现 dht ... -
ajax:Add exception message to json response
2011-05-06 10:07 1936Add exception message to json r ... -
W3C DOM 之 (nodeName || tagName) && nodeType && nodeValue
2010-11-21 16:34 1282tagName和nodeName的区别 http://blog ... -
Js之appendChild() insertBefore() 和扩展的 insertAfter()
2010-11-21 16:14 2992JavaScript之appendChild、insertBe ... -
Extending js Array Prototype
2010-08-11 16:55 1290Extending array prototype with ... -
parentNode与parentElement区别 childNodes与children区别
2010-08-11 11:47 2848parentElement and children is f ... -
readonly和Disabled的区别;display:none和visible:hidden的区别
2010-07-29 11:59 4027Readonly和Disabled: http://www.c ... -
Editable Select 可编辑select
2010-03-30 18:58 7271极棒的一段Editale Select代码: http://w ... -
多用try catch做js调试
2010-03-27 15:00 2412碰到莫名其妙的js错误,多用try catch做调试! 在调 ... -
当onblur遇到focus()
2010-03-19 13:46 2089当onblur触发的function中使用了aElement. ... -
URL中文乱码问题
2010-01-22 00:19 1998解决办法: 一 使用form做提交 二 前台jsp页面编码方 ... -
页面局部刷新的两种方式:form+iframe 和 ajax
2010-01-21 14:41 167551 使用form做提交,target设为iframe的name ... -
frame,iframe,frameset之间的关系与区别
2009-11-12 15:11 1843http://www.cnblogs.com/wennxxin ... -
使用JS刷新showModalDialog窗口
2009-09-26 21:28 3717http://midnightair.iteye.com/bl ... -
getElementsByName无法获得Div
2009-09-20 14:40 2835<input name="test" ... -
js 去掉html标记 去掉换行
2009-09-16 20:15 2750mymsg=mymsg.replace(/<\/?. ... -
document.getElementById为空或不是对象的解决方法
2009-09-11 09:32 4311在使用document.getElementById时,遇到个 ... -
十大JavaScript函数 Top 10 custom JavaScript functions
2009-09-03 22:38 2071http://www.dustindiaz.com/basem ... -
关于js 中的 $()
2009-09-03 21:22 2082并不是js的什么特殊用法。其实只是你的页面引用到的js(或被i ...
相关推荐
jQuery源码jQuery源码jQuery源码jQuery源码jQuery源码jQuery源码jQuery源码jQuery源码jQuery源码jQuery源码jQuery源码jQuery源码jQuery源码jQuery源码jQuery源码jQuery源码jQuery源码jQuery源码jQuery源码jQuery源码...
jquery插件库(jquery.treeview插件库)jquery插件库(jquery.treeview插件库)jquery插件库(jquery.treeview插件库)jquery插件库(jquery.treeview插件库)jquery插件库(jquery.treeview插件库)jquery插件库(jquery....
jquery-3.6.0.js 和 jquery-3.6.0.min.js 【jquery-3.6.0包合集】 jquery-3.6.0包合集下载 包含: jquery-3.6.0.js jquery-3.6.0.min.js jQuery是一个快速、简洁的JavaScript框架,封装JavaScript常用的功能代码,...
jquery-3.7.0.min.js(jQuery下载)jquery-3.7.0.min.js(jQuery下载)jquery-3.7.0.min.js(jQuery下载)jquery-3.7.0.min.js(jQuery下载)jquery-3.7.0.min.js(jQuery下载)jquery-3.7.0.min.js(jQuery下载)...
"jquery-3.4.1_sangat1_jquery3.4.1"可能指的是一个特定的项目或者命名约定,"sangat1"可能是项目名或者是个人开发者的名字,而"jquery3.4.1"是jQuery库的另一种写法,它们都指向同一种资源——jQuery 3.4.1。...
JavaScript+jQuery 网页特效设计 jQuery(3.4.1)基础 1 jQuery简介 jQuery优势 jQuery安装 jQuery语法 1、jQuery简介 1.1 学习jQuery之前,需要以下基础知识 HTML CSS JavaScript 1、jQuery简介 1.2 什么是jQuery? ...