sanders_yao
版主
  
or2 =333
UID 30286
精华
0
积分 2531
帖子 4699
金钱 2528 喜悦币
威望 0
人脉 3
阅读权限 100
注册 2004-7-23 来自 北京 菜户营
状态 离线
|
[推荐阅读] 用gd生成图片,能不能同页加上text的描述(并非在图片上加上text)
抱歉,如果要匹配多行的话我的那个需要这样写:
preg_match_all("~<a.+?href=(?:\'|\")?([^ >\'\"]+)(?:\'|\")?.*?>~is", $str, $arrayClip);
测试过没有问题
$str = "<a href=http://www.xx.com> <a href='http://www.xx.com'> <a href=a.htm> <a href=./a.htm> <a href=http://house.focus.cn/news/2006-07-04/219310.html
target=_blank class=blue1>美国70%房奴</a><br> <a href=http://www.xx.com/> <a href=\"http://www.xx.com/\">";
preg_match_all("~<a.+?href=(?:\'|\")?([^ >\'\"]+)(?:\'|\")?.*?>~s", $str, $arrayClip);
print_r($arrayClip[1]);
[ 本帖最后由 sanders_yao 于 2006-7-4 11:48 AM 编辑 ]
|  最近写的一些代码都会在以下地址发布,有兴趣的来批:
http://www.phpx.com/happy/thread-131368-1-1.html |
|