javasript
文章平均质量分 59
泯梦幽思
这个作者很懒,什么都没留下…
展开
-
Jquery加载页面的方法(页面加载完成就执行)
1、$(function(){ $("#a").click(function(){ //adding your code here }); }); 2、$(document).ready(function(){ $("#a").click(function(){ //adding your code here }); });转载 2011-12-01 14:22:01 · 7770 阅读 · 0 评论 -
JSON与JAVA的数据转换
JSON-lib这个Java类包用于把bean,map和XML转换成JSON并能够把JSON转回成bean和DynaBean。下载地址:http://json-lib.sourceforge.net/还要需要的第3方包:org.apache.commons(3.2以上版本)org.apache.oronet.sf.ezmorph(ezmorph-1.0.4.jar)nu.x转载 2011-12-23 09:33:38 · 888 阅读 · 0 评论 -
jquery 获取父窗口的元素 父窗口 子窗口 各窗口关系
$("#父窗口元素ID",window.parent.document); 对应javascript版本为window.parent.document.getElementByIdx_x("父窗口元素ID"); 取父窗口的元素方法:$(selector, window.parent.document);那么你取父窗口的父窗口的元素就可以用:$(selector, window.pa转载 2011-12-13 10:11:59 · 3243 阅读 · 1 评论 -
jquery radio取值,checkbox取值,select取值,radio选中,checkbox选中,select选中,及其相关
获取一组radio被选中项的值var item = $('input[@name=items][@checked]').val();获取select被选中项的文本var item = $("select[@name=items] option[@selected]").text();select下拉框的第二个元素为当前选中值$('#select_id')[0].selected转载 2011-12-01 15:21:52 · 698 阅读 · 0 评论 -
Kaptcha验证码配置项
web.xml: Kaptcha com.google.code.kaptcha.servlet.KaptchaServlet Border around kaptcha. Legal values are yes or no. kaptcha.border no转载 2011-12-19 10:33:33 · 5823 阅读 · 0 评论 -
JS窗口问题处理:使弹出窗口保持前端显示的几种方法,及window窗体对象open()和showModalDialog()用法
用window.open打开一个窗口,怎么使它一直在父窗口的上面,除非点击自己设置的关闭按钮,我试了一下onblur="self.focus"好像不管用.可使用:opened=window.open("demo.html","demo","left=80,top=60,width=640,height=480,help:no,resizable:no"); opened.focus()转载 2011-12-12 15:39:55 · 7343 阅读 · 0 评论 -
jQuery操作Table学习总结
Query在客户端操作Table学习:不过有很多很多的不足,还需要学习掌握。 .hover { background-color:red; } 姓名 性别 密码 地址转载 2011-12-12 15:16:41 · 648 阅读 · 0 评论 -
hcqenjoy 利用jquery获取input表单值的源码
jquery取radio单选按钮的值$("input[name='items']:checked").val();jquery radio取值,checkbox取值,select取值,radio选中,checkbox选中,select选中,及其相关 获取一组radio被选中项的值 var item = $('input[name=items][checked]').val(); 获取se转载 2011-12-01 18:24:00 · 985 阅读 · 0 评论 -
jquery 遍历对象、数组、集合
使用了jquery有段时间了,整理下jquery中的遍历问题。1.jquery遍历对象 NewDocument type="text/javascript"> $(function(){ var tbody =""; //------------遍历对象 .each的使用------------- //对转载 2011-12-01 15:14:37 · 1359 阅读 · 2 评论 -
location.href用法总结
javascript中的location.href有很多种用法,主要如下。self.location.href=”/url” 当前页面打开URL页面location.href=”/url” 当前页面打开URL页面windows.location.href=”/url” 当前页面打开URL页面,前面三个用法相同。this.location.href=”/url” 当前页面打开URL页转载 2011-12-01 14:38:27 · 18747 阅读 · 0 评论 -
JQuery ajaxSubmit提交中文乱码的解决方案
一般人使用是jQuery(form).ajaxSubmit({ url: "ajaxsub.aspx?abc=test", type: "post", dataType: "json", success: data}); 分析:JQuery的AJAX提交,会将要提交的数据进行编码,使用encodeURIComponent在js中处理数据。因此,无论是 Firefox或者转载 2012-05-03 15:41:35 · 7359 阅读 · 0 评论