php临时笔记
2016-06-27 20:04 hduhans 阅读(38) 评论(0) 收藏 举报1、php返回图片
header('Content-type: image/gif');
echo file_get_contents(ROOT_PATH.'/Public/img/pix.gif');
2、php正则匹配内容
$str = "<h1>标题啊</h1>";
preg_match("/<h1>(.*)<\/h1>/isU", $str, $data_arr);
var_dump($data_arr[1]);
浙公网安备 33010602011771号