首页  >  文章  >  后端开发  >  想用PATH_INFO功能。但是不知道应该加到哪里?解决办法

想用PATH_INFO功能。但是不知道应该加到哪里?解决办法

WBOY
WBOY原创
2016-06-13 13:34:57719浏览

想用PATH_INFO功能。但是不知道应该加到哪里?
这是一个查看网页源代码的功能
网址是这样的
www.vipcha.net/5/
我想实现的功能是这样的
www.vipcha.net/5/www.baidu.com //在原来的基础上增加一个网址。


代码如下: 请高手指点一下。谢谢

PHP code
<!--

Code highlighting produced by Actipro CodeHighlighter (freeware)
http://www.CodeHighlighter.com/

--><?php $hu = 'yuan';
@require_once('global.php');
$domain = $_POST['domain'];
if($domain){
    is_domain($domain) or exit( "<script language=javascript>alert('请输入正确的域名!');location.href='index.php';");
    $content = @file_get_contents("http://".$domain);
    @require_once('cache.php');
    if(file_exists("cache/cache.php")){
        @require_once("cache/cache.php");
        $urls = filehave($urls,$domain);
    }else{
        $urls = fileno($domain);
    }
    writeover("cache/cache.php","<?php \r\n\$urls=".vvar_export($urls).";\r\n?>");
}
?>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>缃</title>
声明:
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系admin@php.cn