sports98
(sports98)
新手上路

一般会员
UID 8263
精华
0
积分 38
帖子 37
金钱 38 喜悦币
威望 0
人脉 0
阅读权限 10
注册 2001-5-17
状态 离线
|
[推荐阅读] 承接php,jsp,asp,ajax等项目开发
先回复一下,不知道成不成。问问斑竹吧
<?php
$str =' ××××××<a href="http://www.xxx.cn/用水计划1.doc">点击查看</a> xxxxxxx××××××<a href="http://www.xxx.cn/用水计划2.doc">点击查看</a> xxxxxxx××××××<a href="http://www.xxx.cn/用水计划3.doc">点击查看</a> xxxxxxx××××××<a href="http://www.xxx.cn/用水计划4.doc">点击查看</a> xxxxxxx××××××<a href="http://www.xxx.cn/用水计划5.doc">点击查看</a> xxxxxxx××××××<a href="http://www.xxx.cn/用水计划6.doc">点击查看</a> xxxxxxx'; //echo $str; preg_match_all("/href=\"http://([wd:/.x80-xff]*)\"/",$str,$array); $str = eregi_replace("href=\"http://([0-9a-zA-Z:/.x80-xff]*)\"","href=\"http://%s\"",$str); foreach($array[1] as $key=>$value) { $s[$key] = urlencode($value); $_s[] = "$s[$key]"; } $__s = join(",",$_s); eval("$vstr = sprintf('".$str."',$__s);");
echo "MSG:".$vstr; ?> 唠叨这方面比较强悍些~
|
|