重定向页面,而无需使用延伸htaccess的 [英] Redirect a page without extention using htaccess

查看:116
本文介绍了重定向页面,而无需使用延伸htaccess的的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我需要重定向页面是这样的:

I need redirect the page like this:

http://www.example.com/index.php

要这样:

http://www.example.com/home

这是使用htaccess的可能吗?如果答案是肯定的,怎么了?

Is this possible using htaccess? And if the answer is yes, how?

推荐答案

是的,这是可能的。将下面的code在的.htaccess 文件:

Yes, this is possible. Put the following code in your .htaccess file:

RewriteEngine on

RewriteRule ^home$ index.php


看一看本网站。这是一个很好的参考。


Have a look at this website. It is a good reference.

这篇关于重定向页面,而无需使用延伸htaccess的的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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