js
文章平均质量分 63
smile_juan
这个作者很懒,什么都没留下…
展开
-
判断是否为数字
<br />1. 判断数字<br />第一种方式<br />var mem_value = frm.mem_id.value;<br />for(var i=0; i<mem_value.length; i++){<br />if(mem_value.charAt(i)<'0'|| mem_value.charAt(i)>'9'){<br />alert("会员号只能是数字");returnfalse;<br />}<br />}<br /><br /><br />第二种方式<b原创 2011-03-21 22:38:00 · 1455 阅读 · 1 评论 -
写的一些js
<br /><br />php和js配合后,后台进行的<br />function editCate(id){<br />var name = document.getElementById(id).value;<br />if(name == ""){<br />alert("名字不能为空");<br />}else{<br />$.post( APP+'/Index/editCatagory',{<br /> id:id,<br /> name:name<br /> }原创 2011-03-30 16:52:00 · 472 阅读 · 0 评论 -
Liferay Inter-portlet communication(client side)
It's very easy to do that. Liferay provides script to do that.This is the syntax: Liferay.fire(eventName, data) Liferay.on(eventName, function, [scope])In my case, one portlet just sends转载 2013-02-08 01:44:23 · 953 阅读 · 0 评论 -
jQuery cache
Yesterday I spent a lot of time on catch this problem. In my app, I need to make a GET Ajax request call to server side. After it's getting the time to DEV, I found the same URL will not be responded.原创 2013-02-09 06:58:39 · 1069 阅读 · 0 评论