来自http://www.keepmyway.com/index.php/91.html关键字:cache-control, expire, if-none-match, if-modified-since, etag, last-modified请求处理过程:当一个用户发起一个静态资源请求的时候,...
分类:
Web程序 时间:
2014-10-20 13:08:05
阅读次数:
278
这两个是按钮开关,监听CheckedChangeListener
toggle_layout.xml:
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match...
分类:
移动开发 时间:
2014-10-20 11:46:59
阅读次数:
245
1. 验证E-mail地址这是一个用于验证电子邮件的正则表达式。但它并不是高效、完美的解决方案。在此不推荐使用。 $email = "test@ansoncheung.tk"; if (preg_match('/^[^0-9][a-zA-Z0-9_]+([.][a-zA-Z0-9_]+)*[@][a...
分类:
Web程序 时间:
2014-10-17 16:51:42
阅读次数:
232
加一个红色的边框:
textView的XML:
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orienta...
分类:
移动开发 时间:
2014-10-17 13:54:32
阅读次数:
275
效果:
1.自定义titleBar的布局。
android:layout_width="match_parent"
android:layout_height="match_parent" >
android:id="@+id/tv_SongsCount"
android:layout_widt...
分类:
其他好文 时间:
2014-10-17 13:52:21
阅读次数:
203
要求匹配字符,开始与结束的值相等,中间只能为数字$str = 'a123a';preg_match('/^(\w)[\d]*(\1)$/',$str,$res);print_r($res);---------------(\1)引用第一次大括号里的值,以些类推(\2)(\3)
分类:
其他好文 时间:
2014-10-16 16:22:12
阅读次数:
160
效果:
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="#FFFFFF"
android:orientation="vertical" >
android:lay...
分类:
移动开发 时间:
2014-10-16 12:58:12
阅读次数:
175
1.新建正则表达式,有两种方式var exp1:RegExp = new RegExp("ABCD","g");var exp2 = /ABCD/g;//g global 表示全局匹配trace("ABCDEFABCD".match(exp1));trace("ABCDEFABCD".match(e...
分类:
其他好文 时间:
2014-10-16 02:07:01
阅读次数:
302
Fragment在实际项目开发中使用的越来越多,现在简单介绍一下
布局文件:
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_par...
分类:
移动开发 时间:
2014-10-15 22:54:41
阅读次数:
265
http://acm.nyist.net/JudgeOnline/problem.php?pid=15
dp[i][j]表示从i到j至少需要添加多少个括号才能满足匹配条件.
初始化:
if(i == j)
dp[i][j] = 1;
else
dp[i][j] = INF;
状态转移:
当i
if(match(str[i], str[j])) dp[i]...
分类:
其他好文 时间:
2014-10-15 18:44:31
阅读次数:
259