Home > Backend Development > PHP Tutorial > urlrewrite 写法,不常用,请问

urlrewrite 写法,不常用,请问

WBOY
Release: 2016-06-13 10:09:21
Original
826 people have browsed it

urlrewrite 写法,不常用,请教
我要输入http://www.aa.com 跳转到 http://www.aa.com/quote

怎么写??

要求一定要用url重写

不能在index.php文件里header(location:)

------解决方案--------------------

PHP code
RewriteEngine onRewriteCond %{HTTP_HOST} www.aa.com$RewriteCond %{REQUEST_URI} !^/quote/RewriteCond %{REQUEST_FILENAME} !-fRewriteCond %{REQUEST_FILENAME} !-dRewriteRule ^(.*)$ /quote/$1<div class="clear">
                 
              
              
        
            </div>
Copy after login
Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template