正则表达式match()函数:此方法可在字符串内查找一个或多个正则表达式的匹配。返回值是一个数组,但是此数组的内容和正则对象是否是全局匹配有着很大关系:1.没有g修饰符:此方法只能够在字符串中匹配一次。如果没有找到匹配的字符串,那么返回null,否则将返回一个数组,数组的第0个元素存储的是匹配字符串...
分类:
其他好文 时间:
2015-09-26 12:00:01
阅读次数:
266
Loaded plugins: fastestmirrorLoading mirror speeds from cached hostfilehttp://ftp.sjtu.edu.cn/centos/5.4/addons/x86_64/repodata/primary.sqlite.bz2: [E...
分类:
数据库 时间:
2015-09-24 19:18:53
阅读次数:
1455
一些小笔记 getFields: function(text) { try { var fields = []; var matched = text.match(/{{[A-Za-z0-9_\(\)]+}}/g); i...
分类:
其他好文 时间:
2015-09-24 15:59:09
阅读次数:
144
preg_match_all('/]*src=(\'|\")(.*?)\\1[^>]*>/i',$goodsD['content'],$match); //正则获取图片路径获取到结果为:array (size=3) 0 => array (size=2) 0 => string ...
分类:
其他好文 时间:
2015-09-24 10:44:28
阅读次数:
195
首先是主要布局 <android.support.v4.widget.SwipeRefreshLayout
xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@+id/swipeRefreshLayout"
android:layout_width="match_parent"
an...
分类:
移动开发 时间:
2015-09-22 23:48:02
阅读次数:
499
好吧……我承认很尴尬……但毕竟作为开端,还是将这个贴出来,以后一定写出厉害的!<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent...
分类:
移动开发 时间:
2015-09-22 06:42:18
阅读次数:
201
]*>/i', $text, $match); //打印出match print_r($match);
分类:
Web程序 时间:
2015-09-21 23:49:56
阅读次数:
181
<android.support.v7.widget.RecyclerView
android:layout_width="match_parent"
android:layout_height="match_parent"
android:scrollbars="vertical"
>
...
分类:
其他好文 时间:
2015-09-21 12:35:04
阅读次数:
513
jQuery数字的截取:str.toFixed(num);//小数的截取toFixed()js:parseInt(num) ;//丢弃小数部分,保留整数部分php抓取网页内容:正则表达式匹配筛选抓取的内容:preg_match('/[0-9]{1,2}.[0-9]{4}/',$contents,$s...
分类:
Web程序 时间:
2015-09-21 00:04:35
阅读次数:
202
#include<stdio.h>#include<errno.h>#include<assert.h>typedefenumSTATE{ SUCCESS, //成功 FILE_ERROE, //文件错误 NO_MATCH, //不匹配 OTHER, //其他错误}STATE;typedefenumTAG{ TAG_BEGIN, //在C注释段中 TAG_END, //C注释结束}TAG;#pragmawarning(dis..
分类:
其他好文 时间:
2015-09-20 07:01:23
阅读次数:
144