摘要: 一、收集处理数据分三步: 提取js中的信息(Response看的不清楚,使用Preview比较方便,Preview把这个资料整理成Json,所以用json提取信息,url在Headers中,还有method方法) 阅读全文
posted @ 2017-07-21 22:45 wskxy 阅读(222) 评论(0) 推荐(0)
摘要: list1=[1,2,3,4,5]list2=[6,7,8]list1.append(list2) #添加集合[6,7,8] 结果:[1,2, 3, 4, 5, [6, 7, 8]]list1.extend(list2) #添加集合内各个元素 结果:[1,2, 3, 4, 5, [6, 7, 8], 阅读全文
posted @ 2017-07-16 15:48 wskxy 阅读(141) 评论(0) 推荐(0)
摘要: 1..net ajax显示后台返回值 <script> $(document).ready(function () { $("#btn").click(function () { //var data = new string(); $.ajax({ type: "POST", //要用post方式 阅读全文
posted @ 2017-04-28 21:28 wskxy 阅读(589) 评论(1) 推荐(0)
摘要: 1.加载外部文件 <html><head><meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <!--防止乱码--><script src="js/jQuery.js"></script> <!--加载jQuery文 阅读全文
posted @ 2017-04-12 12:45 wskxy 阅读(249) 评论(0) 推荐(0)
摘要: 1.父元素 $("span").parent() //定位到span的父元素 $("span").parents() //定位到span的所有父元素 $("span").parents("ul") //定位到span的ul父元素 $("span").parentsUntil("div"); //指定 阅读全文
posted @ 2017-04-11 22:57 wskxy 阅读(787) 评论(0) 推荐(0)
摘要: 1.取值 $("#test").text() //取id=test里面的文字 $("#test").text("hello jquery") //设置id=test里面的文字 $("#test").html() //取id=test里面的html $("#test").html("<b>hello 阅读全文
posted @ 2017-04-09 23:01 wskxy 阅读(292) 评论(0) 推荐(0)
摘要: 1.jquery隐藏and显示事件 $("p").hide(); //隐藏事件$("p").hide(1000); //1秒内缓慢隐藏$("p").show(); //显示事件$("p").toggle(); //在隐藏和显示中切换 隐藏后显示提示callback $("p").hide(funct 阅读全文
posted @ 2017-04-07 23:17 wskxy 阅读(1310) 评论(0) 推荐(0)
摘要: 1.如何使用jQuery jQuery是一个快速、简洁的JavaScript框架,是继Prototype之后又一个优秀的JavaScript代码库(或JavaScript框架)。jQuery设计的宗旨是“write Less,Do More”,即倡导写更少的代码,做更多的事情。它封装JavaScri 阅读全文
posted @ 2017-04-07 20:15 wskxy 阅读(445) 评论(0) 推荐(0)
摘要: 1.提示框 1)警告框 <script>function disp_alert(){alert("我是警告框!!")}</script> 2)确认框 function disp_alert(){var r=confirm("Press a button!");//弹出确认框if (r==true) 阅读全文
posted @ 2017-04-05 10:25 wskxy 阅读(272) 评论(0) 推荐(0)
摘要: 1.节点-添加标签 <body><div id="div1"><p id="p1">这是一个段落。</p><p id="p2">这是另一个段落。</p></div><script>var para=document.createElement("p"); //创建一个文本节<p>var node=d 阅读全文
posted @ 2017-04-03 19:05 wskxy 阅读(267) 评论(0) 推荐(0)