是否有可能处理这样的URL [英] Is it possible to handle such URL

查看:129
本文介绍了是否有可能处理这样的URL的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

http://www.example.com/http://www。 test.com

我曾尝试使用的.htaccess没有运气许多不同的方法。我需要获得第二个URL到来的参数。是否有可能将其重定向到的index.php,并把它作为 $ _ SERVER [REQUEST_URI] 或其他的方法?谢谢

UPD:看起来它是不可能得到整个URL,问号无法识别。理想的例子:

  127.0.0.1/http://www.test.com/script.php?a=hello&b=world#blabla;par2?%par3
 

和我需要让我的index.php的确切字符串

  www.test.com/script.php?a=hello&b=world#blabla;par2?%par3
 

解决方案

这是绝对有可能的:的 http://downforeveryoneorjustme.com/http://www.google.com/

至于如何,它一直<一个href="http://serverfault.com/questions/56082/configure-apache-to-handle-all-requests-via-single-index-php">covered对ServerFault 已

http://www.example.com/http://www.test.com

I have tried many different methods using .htaccess with no luck. I need to get that second url coming as parameter. Is it possible to redirect it to index.php and get it as $_SERVER["REQUEST_URI"] or other method? Thanks

UPD: Looks like it is impossible to get whole URL, question marks are not recognized. Ideal example:

127.0.0.1/http://www.test.com/script.php?a=hello&b=world#blabla;par2?%par3 

and i need to get in my index.php exact string

www.test.com/script.php?a=hello&b=world#blabla;par2?%par3

解决方案

It's definitely possible: http://downforeveryoneorjustme.com/http://www.google.com/

As to how, it's been covered on ServerFault already

这篇关于是否有可能处理这样的URL的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆