echo $row->link ."<br>\n";
pr($arr);
echo $arr['path']  ."<br>\n";
$arr2 = pathinfo($arr['path']);
pr($arr2);

Array
(
    [scheme] => http
    [host] => www.58.com
)
Array
(
    [scheme] => http
    [host] => www.moonbasa.com
    [path] => /source.aspx
    [query] => a_id=1188-mingzhan&url=http://www.moonbasa.com/
)
http://jump.all4ad.cn/jump.aspx?id=858
Array
(
    [scheme] => http
    [host] => jump.all4ad.cn
    [path] => /jump.aspx
    [query] => id=858
)
/jump.aspx
Array
(
    [dirname] => \
    [basename] => jump.aspx
    [extension] => aspx
    [filename] => jump
)
http://go2000.tuike.cn/mylink/45
Array
(
    [scheme] => http
    [host] => go2000.tuike.cn
    [path] => /mylink/45
)
/mylink/45
Array
(
    [dirname] => /mylink
    [basename] => 45
    [filename] => 45
)

Posted on 2010-05-18 13:23  古代  阅读(270)  评论(0编辑  收藏  举报