2016年10月14日

wapm 配置

摘要: mysql 用户名rootmysql 密码 自己修改mysql 服务器地址 localhost use mysql; 重新修改 update mysql.user set password=PASSWORD(需要修改的密码)where user='root'; 修改阿帕奇端口 在阿帕奇配置文件里面 阅读全文

posted @ 2016-10-14 10:53 奔跑的葛根 阅读(185) 评论(0) 推荐(0) 编辑

2016年9月28日

给别的DIV上面加事件

摘要: 这是一个层 点击挂上事件 点击移除事件 function showdd() { alert("被点中了"); } function add1() { var d = document.getElementById("dd"); d.onclick = function (){showdd()}; //匿名函数 } function remove1() { var d = documen... 阅读全文

posted @ 2016-09-28 09:07 奔跑的葛根 阅读(304) 评论(0) 推荐(0) 编辑

2016年9月27日

表单验证

摘要: 密码正则表达:^[\@A-Za-z0-9\!\#\$\%\^\&\*\.\~\,\_\-\`]{6,15}$ 非空验证 function Check() { var v= document.getElementById("uid").value if( v.trim().length==0) {alert("用户输入的内容不能为空" ... 阅读全文

posted @ 2016-09-27 11:48 奔跑的葛根 阅读(134) 评论(0) 推荐(0) 编辑

2016年9月23日

图片轮播

摘要: $(".aa").click(function(){ var cc=$(this).index(); var bb=document.getElementsByClassName("bb"); for(var i=0;i<bb.length;i++) { bb[i].style.display="n 阅读全文

posted @ 2016-09-23 17:07 奔跑的葛根 阅读(157) 评论(0) 推荐(0) 编辑

例题 从这复制到那边

摘要: <select id="aa" style=" width:200px; height:200px"size="10"> <option >123</option> <option>234</option> <option>345</option> <option>355</option> </se 阅读全文

posted @ 2016-09-23 11:52 奔跑的葛根 阅读(126) 评论(0) 推荐(0) 编辑

2016年9月22日

document 对象

摘要: 找元素 根据ID找 alert(document.getElementById("b")); 根据class找var attr = document.getElementsByClassName("aa");alert(attr[2]); 根据name找alert(document.getEleme 阅读全文

posted @ 2016-09-22 17:55 奔跑的葛根 阅读(138) 评论(0) 推荐(0) 编辑

DOM:文档对象模型 --树模型

摘要: 间隔和延迟: window.setInterval("要执行的代码",间隔的毫秒数) window.clearInterval(间隔的id); 循环一次之后用来清除隔几秒执行的代码 window.setTimeout("要执行的代码",延迟的毫秒数) window.clearTimeout(延迟的i 阅读全文

posted @ 2016-09-22 17:17 奔跑的葛根 阅读(300) 评论(0) 推荐(0) 编辑

2016年9月21日

函数

摘要: random() 返回 0 ~ 1 之间的随机数。 length 属性 *******返回字符串的长度,所谓字符串的长度是指其包含的字符的个数 replace *******替换字符串,第一个参数代表被替换的字符串,第二个参数代表替换的字符串 split ******通过将字符串划分成子串,将一个字 阅读全文

posted @ 2016-09-21 22:53 奔跑的葛根 阅读(142) 评论(0) 推荐(0) 编辑

2016年9月19日

冒泡排序 与二分法 -递归

摘要: <script type="text/javascript"> //var attr = [1,8,26,4,15,3,7,42,9]; //对数组元素进行排序//冒泡排序/*8 6 4 5 3 7 2 9 1 88 6 5 4 7 3 9 2 1 7 8 6 5 7 4 9 3 2 1 68 6 阅读全文

posted @ 2016-09-19 15:22 奔跑的葛根 阅读(258) 评论(0) 推荐(0) 编辑

数组

摘要: 数组:相同类型数据的集合 数组强类型语言:1.数组里面只能存放相同数据类型的数据 2.定义数组的时候需要制定一个长度(可以存放的元素数量)3.内存空间连续 集合强类型语言:1.可以存放任意类型的数据2.定义的时候不需要指定长度3.内存空间不连续 JS:数组:1.可以存放任意类型数据2.定义时候不需要 阅读全文

posted @ 2016-09-19 10:38 奔跑的葛根 阅读(150) 评论(0) 推荐(0) 编辑

导航