可能重复:
How to redirect all requests to index.php and keep the other GET params?
Rerouting all php requests through index.php如何为一组路径调用特定的PHP脚本?
假设我们有/var/www/someapp/index.php
脚本。现在,我们怎样才能使Apache服务器发送所有喜欢
http://somedomain.info/someapp/alpha
http://somedomain.info/someapp/beta
http://somedomain.info/someapp/beta/gamma
http://somedomain.info/someapp/epsilon/omega
...到非常index.php
脚本网址的请求的,以及我们如何能够从PHP脚本中检索完整的路径?
请参阅[StackOverflow常见问题](http://stackoverflow.com/faq),特别是关于[不要问什么](http://stackoverflow.com/faq/#dontask)的部分,即:* “如果你可以想象一整本书可以回答你的问题,那么你的问题就太多了。”* – orourkek 2012-08-15 22:27:43
此外,这是[this]的重复(http://stackoverflow.com/questions/9694118/rerouting-all- php-requests-through-index-php),[this](http://stackoverflow.com/questions/3776714/htaccess-rewriting-all-requests-to-a-single-controller?rq=1),[this ](http://stackoverflow.com/questions/5214502/how-to-redirect-all-requests-to-index-php-and-keep-the-other-get-params)和[this](http: //stackoverflow.com/questions/2669258/redirect-everything-to-index-php),名称*只有几个* ... – orourkek 2012-08-15 22:30:50
[这里有几十个更多](https://www.google.com/search q =站点%3Astackoverflow.com +重定向+〜+所有子目录〜+至+〜+单文件),如果任何人有兴趣。 – orourkek 2012-08-15 22:40:27