1. URL重写组件url-rewrite2

微软官方下载地址

http://www.iis.net/downloads/microsoft/url-rewrite

下载安装

导入.htaccess 文件   点击应用

 

Apache 环境

httpd.conf文件。打开后找到DirectoryIndex

将默认的index.html文件改为index.php文件(任意自己想设置的入口文件)

找到mod_rewrite.so  去掉当前行注释,加载重写模式

2.将所有AllowOverride 后的默认设置None改为:All

 

并且在ThinkPHP文件config文件中配置重写模式为2:

    //rewriter重写模式
    'URL_MODEL'=>2,

 

相关文章:

  • 2022-12-23
  • 2022-03-09
  • 2021-07-04
  • 2022-12-23
  • 2021-09-06
  • 2022-12-23
  • 2021-11-22
  • 2021-12-24
猜你喜欢
  • 2022-12-23
  • 2022-12-23
  • 2021-09-30
  • 2021-11-25
  • 2021-10-19
  • 2021-11-28
  • 2022-12-23
相关资源
相似解决方案