function param(name) { var reg = new RegExp("(^|&)" + name + "=([^&]*)(&|$)"); var r = window.location.search.substr(1).match(reg); if (r ...
分类:
Web程序 时间:
2015-09-16 14:10:38
阅读次数:
118
摘自:《TheWebApplicationHacker‘sHandbook》中文名:《黑客攻防技术宝典Web实战篇》(第二版)OracleMS-SQLMySQLASCII和substringASCII(‘A‘)SUBSTR(‘ABCDE‘,2,3)ASCII(‘A‘)SUBSTRING(‘ABCDE‘,2,3)ASCII(‘A‘)SUBSTRING(‘ABCDE‘,2,3)获取当前数据库用户SelectSys.login_userfro..
分类:
数据库 时间:
2015-09-15 20:22:50
阅读次数:
230
1. JS中substring与substr的区别之前在项目中用到substring方法,因为C#中也有字符串的截取方法Substring方法,当时也没有多想就误以为这两种方法的使用时一样的。这样就直接按照在C#中使用Substring的方式,直接在js中用了substring,在实际的项目中,有时...
分类:
Web程序 时间:
2015-09-15 16:19:52
阅读次数:
134
这里用到String类库里的indexOf()函数和subString()函数。 直接贴源码: ?static?int?countStr(String?str,String?subStr){
??
??int?count?=?0;
??if(str.indexOf(subStr)==-1)
???return?0;
...
分类:
其他好文 时间:
2015-09-15 11:15:51
阅读次数:
124
http://acm.hdu.edu.cn/showproblem.php?pid=5007纯粹的联系String的substr什么时候substr拦截比写短话string te; int n; te="Hellow"; cout #include #include #includ...
分类:
其他好文 时间:
2015-09-12 20:16:00
阅读次数:
134
php对文本文件进行分页功能简单实现 Paging "; } if(ord(substr($str, $i, 1))>0xa0){ $tmp_str .= substr($str, $i, 2); $i++;...
分类:
Web程序 时间:
2015-09-10 15:43:12
阅读次数:
136
由于在项目中有需要对字符串进行截取,然后手残使用了IDE自动提示的substr,没想那么多以为substr和substring没多大区别。然而并不是,且听我一一道来。1. substr(index, length)从起始索引号提取字符串中指定数目的字符。 substr方法可以传入两个参数 index...
分类:
编程语言 时间:
2015-09-10 00:12:20
阅读次数:
232
题目:Compare two version numbersversion1andversion2.Ifversion1>version2return 1, ifversion1 -1) { v1 = atoi(version1.substr(0, pos1).c_st...
分类:
其他好文 时间:
2015-09-09 20:59:22
阅读次数:
159
Pretty PoemTime Limit: 2 Seconds Memory Limit: 65536 KBPoetry is a form of literature that uses aesthetic and rhythmic qualities of language. There...
分类:
其他好文 时间:
2015-09-09 17:21:54
阅读次数:
163
Pretty PoemTime Limit: 2 Seconds Memory Limit: 65536 KBPoetry is a form of literature that uses aesthetic and rhythmic qualities of language. There...
分类:
其他好文 时间:
2015-09-09 16:35:39
阅读次数:
174