laravel框架实现去掉URL中index.php的方法
2019-10-13 07:05
1401 查看
1、将框架根目录下的server.php文件重命名为index.php
2、将框架根目录下的文件夹public下的.htaccess文件复制到框架根目录下,与index.php处于同一目录
3、修改Apache的httpd.conf文件
1、httpd.conf文件所在路径\bin\apache\apache2.4.23\conf\httpd.conf,例如,我的电脑中httpd.conf路径为:D:\wamp\bin\apache\apache2.4.23\conf\httpd.conf
找到httpd.conf文件之后,我们就来修改他吧!
2、在154行左右,找到#LoadModule rewrite_module modules/mod_rewrite.so代码,去掉代码前面的#号
3、重启Apache服务
现在是不是不用在URL中输入讨厌的index.php也能访问web项目了呢!
以上这篇laravel框架实现去掉URL中index.php的方法就是小编分享给大家的全部内容了,希望能给大家一个参考
您可能感兴趣的文章:
相关文章推荐
- apache 中实现 laravel框架去掉url中包含的index.php后缀
- laravel框架如何去掉URL中index.php
- CI 框架去掉url 中index.php的方法
- Apache下简化URL,去掉index.php的方法
- CI框架去掉URl中的index.php部分
- CI框架apache和nginx环境下面统一去掉路径URL后面的index.php
- CodeIgniter框架去掉url中的index.php
- win/Linux下去掉codeigniter框架网站URL中的“index.php”
- SSO单点登录的PHP实现方法(Laravel框架)
- 在nginx下去掉ci框架url中的index.php
- CI框架在Apache服务器下去掉URL中的index.php
- PHP CodeIgniter(CI)框架中去掉 index.php方法
- CI框架在 nginx 服务器上配置 rewrite 去掉 index.php 的方法:
- CodeIgniter框架去掉url中的index.php
- thinkphp在wamp 配置去掉url中index.php方法
- CodeIgniter 去掉/去除/删除 URL中index.php 的方法
- SSO单点登录的PHP实现方法(Laravel框架)
- php中关于ci框架修改后缀并去掉url中的index.php
- thinkPHP如何去掉url中的index.php
- 如何去掉CodeIgniter URL中的index.php