passer1991

2013年8月21日

如何限制文本框中的字数

摘要: function checkLength(which,remainderNum,maxChars) { setTimeout(function() { if (which.value.length > maxChars) which.value = which.value.substring(0,maxChars); var curr = maxChars - which.value.length; //document.getElementById().innerHTML = curr.toString(); $("#"+remainderNum).text(cur 阅读全文

posted @ 2013-08-21 17:57 passer1991 阅读(206) 评论(0) 推荐(0) 编辑

jquery如何设置控件位置

摘要: http://www.1000year.com/blog/834/http://blog.csdn.net/wyqlxy/article/details/6728934 var offsettop=$("#form1 table").offset().top; var offsetleft=$("#form1 table").offset().left; $("#prompt").css({position: "absolute",'top':offsettop,'left':off 阅读全文

posted @ 2013-08-21 14:16 passer1991 阅读(276) 评论(0) 推荐(0) 编辑

jquery中this的作用域

摘要: $("#btn1").click(function(){ var thisOne=$(this); $.post("url",function(data){ var thisTwo=$(this); });});注意:thisTwo和thisOne不是同一个对象. 阅读全文

posted @ 2013-08-21 13:46 passer1991 阅读(190) 评论(1) 推荐(0) 编辑

导航