上一页 1 ··· 3 4 5 6 7 8 9 下一页
摘要: 5.1函数的定义有3种方式:声明式函数,匿名函数和函数直接量。通过匿名函数可以使用户来定义函数的函数体:其中最后一个参数是函数体,前面的都是函数的参数。var func = prompt("输入函数");var x = prompt("输入x的值:");var y = prompt("输入y的值:"... 阅读全文
posted @ 2015-07-27 20:20 流殇微 阅读(191) 评论(0) 推荐(0) 编辑
摘要: var dt = new Date();dt.setDate(26);dt.setMonth(7);dt.setYear(2015);dt.setHours(21);dt.setMinutes(46);document.writeln(dt.toString() + " ");document.wr... 阅读全文
posted @ 2015-07-26 21:50 流殇微 阅读(252) 评论(0) 推荐(0) 编辑
摘要: var rgExp = /(^\D*[0-9])/; var str = "this is fun 01 stuff";var resu = str.match(rgExp);document.writeln(resu);结果为: this is fun 0,this is fun 0如果使用圆括号... 阅读全文
posted @ 2015-07-26 21:35 流殇微 阅读(765) 评论(0) 推荐(0) 编辑
摘要: 一:结构和调用(实例化):class className{} ,调用:$obj = new className();当类有构造函数时,还应传入参数。如$obj = new className($v,$v2…);二:构造函数和析构函数:1、构造函数用于初始化:使用__construct(),可带参数。... 阅读全文
posted @ 2015-07-19 11:14 流殇微 阅读(377) 评论(0) 推荐(0) 编辑
摘要: PHP中的魔术方法总结 :__construct, __destruct , __call, __callStatic,__get, __set, __isset, __unset , __sleep, __wakeup, __toString, __set_state, __clone and _... 阅读全文
posted @ 2015-07-19 10:27 流殇微 阅读(289) 评论(0) 推荐(0) 编辑
摘要: 2015-7-18 22:02:21PHP表单中需引起注重的地方?$_SERVER["PHP_SELF"] 变量有可能会被黑客使用!当黑 客使用跨网站脚本的HTTP链接来攻击时,$_SERVER["PHP_SELF"]服务器变量也会被植入脚本。原因就是跨网站脚本是附在执行文件的路径 后面的,因此$_... 阅读全文
posted @ 2015-07-18 22:04 流殇微 阅读(3054) 评论(0) 推荐(0) 编辑
摘要: 2015-7-15 22:39:41在win7 64位系统之下:可以直接使用pip命令安装或者下载下来django之后,cd到解压开的安装包中,运行 python setup.py install等待安装完成之后,进入python运行环境,使用>>>import django>>>django.VE... 阅读全文
posted @ 2015-07-15 22:46 流殇微 阅读(293) 评论(0) 推荐(0) 编辑
摘要: 测试int>>> help(int)Help on class int in module builtins:class int(object)| int(x=0) -> integer| int(x, base=10) -> integer| | Convert a number or strin... 阅读全文
posted @ 2015-07-15 21:42 流殇微 阅读(757) 评论(0) 推荐(0) 编辑
摘要: 2015-7-14 20:43:44P14:'raw'指示符告诉解释器不要转换字符串中的任何特殊字符。。。例如: filename = r'C:\temp\newfolder\robots.txt'。为了保持一致性,不管一个正则表达式是否用到了反斜杠,通常一律都使用raw字符串。P18:dict.g... 阅读全文
posted @ 2015-07-14 21:25 流殇微 阅读(516) 评论(0) 推荐(0) 编辑
摘要: 2015-7-13 22:45:31P15:如果defer的属性设置为"defer"的话,表示脚本不会生成任何文档内容,浏览器和可以先处理页面的其它部分,之后再返回到脚本。 P17:JavaScript最佳实践:将JavaScript程序代码块放入到外部JavaScript文件中。P21:使用var... 阅读全文
posted @ 2015-07-13 23:17 流殇微 阅读(285) 评论(0) 推荐(0) 编辑
上一页 1 ··· 3 4 5 6 7 8 9 下一页