function isUrl($s) { return preg_match('/^http[s]?:\/\/'. '(([0-9]{1,3}\.){3}[0-9]{1,3}'. // IP形式的URL- 199.194.52.184 '|'. // ...
分类:
Web程序 时间:
2014-08-27 18:26:18
阅读次数:
176
1.关于searchView:
<SearchView
android:id="@+id/search_view"
android:layout_width="0dp"
android:layout_height="match_parent"
android:layout_weight="1"
android:iconifiedByDefault="fal...
分类:
其他好文 时间:
2014-08-27 14:45:32
阅读次数:
280
function get_intime($intime,$format){ if($intime==""){ return ""; } $format = isset($format)?$format:'Y-m-d H:i:s'; if(preg_match('/\d{10,}/is',$inti....
分类:
Web程序 时间:
2014-08-27 12:35:17
阅读次数:
191
JS 验证正则表达式-常用方法javascript所支持的正则表达式常用的六种方法:test(),exec(),match(),search(),replace()和split(). 其中前两者属于RegExp类的方法后,其余属于string类的方法.test()方法:如果给定的字符串匹配该正则的模...
分类:
Web程序 时间:
2014-08-27 12:21:52
阅读次数:
293
first sense for erlang. in Erlang, the things I like? 1. ?= is Pattern Match X?=?X?+?1.?//always?wrong. the things I dislike? 1. some thoughts. ?erlang and prolog....
分类:
其他好文 时间:
2014-08-27 06:04:17
阅读次数:
244
题目地址:HDU 3277这题跟这题的上一版建图方法差点儿相同,仅仅只是须要拆点。这个点拆的也非常巧妙,既限制了流量,还仅仅限制了一部分,曾经一直以为拆点会所有限制,原来也能够用来分开限制,学习了。建图方法为:建一源点与汇点,将女孩进行拆点,拆成i和i+n,将i与源点连边,权值为mid,将i与i+n...
分类:
其他好文 时间:
2014-08-26 19:34:16
阅读次数:
243
本:1.0 日期:2014.8.16 2014.8.23 2014.8.26版权:© 2014 kince 转载注明出处 一、概述 开发中发现在WindowManager上像在Activity中使用动画效果无效,比如下面的代码: ImageView iv = new ImageView(this);
iv.setImageResource(R.drawable...
分类:
移动开发 时间:
2014-08-26 15:31:36
阅读次数:
376
一、SGI STL配置器简介
SGI STL的配置器与众不同,它与标准规范不同。如果要在程序中明确使用SGI配置器,那么应该这样写:
[cpp]
view plaincopyprint?
vectorint,std::alloc> iv;
他的名字是alloc,而且不接受任何参数。标准配置器的名字是allocator,而且可以接受参数。
SGI S...
分类:
其他好文 时间:
2014-08-26 11:49:26
阅读次数:
243
if(!preg_match("/^13[0-9]{1}[0-9]{8}$|15[0-9]{1}[0-9]{8}$|18[0-9]{1}[0-9]{8}$|145[0-9]{8}$$/",$phone)){
echo "alert('手机号不正确!')";
echo "location='register.php'";
exit;
}...
分类:
移动开发 时间:
2014-08-26 11:46:15
阅读次数:
188
1.在XHL中:android:id="@+id/spinner1"android:layout_width="match_parent"android:layout_height="wrap_content"android:entries="@+array/other" />在string.xml...
分类:
移动开发 时间:
2014-08-26 08:34:25
阅读次数:
212