上一页 1 ··· 18 19 20 21 22 23 24 25 26 ··· 35 下一页
摘要: 方式一: ~function() { }(); 方式二: (function() { })(); 方式三: !function(){}(); 方式四: $(document).ready(function(){} 阅读全文
posted @ 2017-08-21 14:37 新年新气象 阅读(100) 评论(0) 推荐(0)
摘要: <script src="http://cdn.static.runoob.com/libs/jquery/1.8.3/jquery.js"></script> {"comments":[{"content":"很不错嘛","id":1,"nickname":"纳尼"},{"content":"哟西 阅读全文
posted @ 2017-08-21 11:58 新年新气象 阅读(132) 评论(0) 推荐(0)
摘要: 内边框: border-top-style border-right-style border-bottom-style border-left-style 等价: border-top-width 综合:宽度,样式,颜色 外边框: 定位: static元素框正常生成。块级元素生成一个矩形框,作为文 阅读全文
posted @ 2017-08-18 09:46 新年新气象 阅读(275) 评论(0) 推荐(0)
摘要: 第一种: 第二种:注意点target和inframe的name必须相等 阅读全文
posted @ 2017-08-17 15:15 新年新气象 阅读(282) 评论(0) 推荐(0)
摘要: html代码: 遍历节点 改变节点的值:下面两句代码等价 改变属性: 添加节点: 删除节点:注意url中间不能有空格,不然第一次删除的是空白节点,不过在ie上不解析空白节点,是没有问题的 遍历body下的节点:(注意:获取body对象方法是document.body而不是document.getEl 阅读全文
posted @ 2017-08-17 12:01 新年新气象 阅读(136) 评论(0) 推荐(0)
摘要: 提示: 确定,取消 文本对话框 // window.open(url,name,features,replace) // 参数1:新打开url name:打开窗口的名字 replace:是否允许url替换窗口的内容 featured:一个字符串,列举窗口特征 阅读全文
posted @ 2017-08-17 09:45 新年新气象 阅读(183) 评论(0) 推荐(0)
摘要: oncontextmenu对象右击 举例1: 等价于: form1.elements['textfield2']如果name=textfield2的控件只有一个,返回的是控件,不是数组,如果有多个,则返回的是数组form1.elements['textfield2'][0] 阅读全文
posted @ 2017-08-16 10:55 新年新气象 阅读(209) 评论(0) 推荐(0)
摘要: var arr = new Array(1,2,3); document.write(arr.length+""); // delete arr[0]; 去掉数组第一个元素,数组长度不变 // arr.pop(); 去掉数组最后一个,数组长度-1 // arr.shift(); 去掉数组第一个,数组长度-1 // arr.push("我","是");//在数组尾部添加元素 // arr.u... 阅读全文
posted @ 2017-08-16 09:59 新年新气象 阅读(105) 评论(0) 推荐(0)
摘要: 第一个hello world 浏览器名称以及版本号 js大小写敏感 (title没有定义这里就直接使用了,js属于弱语言,不定义可以直接使用) 创建对象: 遍历数组: 阅读全文
posted @ 2017-08-15 16:15 新年新气象 阅读(128) 评论(0) 推荐(0)
摘要: 案例1: 案例2: js代码: 注意点: str1是描述,str2是值 获取value: var sell = document.getElementById("sell"); alert(sell.options[sell.options.selectedIndex].value); 获取text 阅读全文
posted @ 2017-08-15 14:51 新年新气象 阅读(278) 评论(0) 推荐(0)
上一页 1 ··· 18 19 20 21 22 23 24 25 26 ··· 35 下一页