Thinkphp框架的网站lnmp无法页面跳转配置

  nginx配置文件修改如下:

清涧网站建设公司成都创新互联,清涧网站设计制作,有大型网站制作公司丰富经验。已为清涧千余家提供企业网站建设服务。企业网站搭建\外贸营销网站建设要多少钱,请找那个售后服务好的清涧做网站的公司定做!

 

server {

  listen       80;

  server_name  debian;

  root /usr/share/nginx/html;

  index  index.php;

  location ~ ^/(api)\.php$ {

    deny all;

  }

  location / {

    if (!-e $request_filename){

      rewrite ^/(.*)$ /index.php/$1 last;

    }

  }

  location ~ \.php($|/){

    set $script     $uri;

    set $path_info  "";

    if ($uri ~ "^(.+?\.php)(/.+)$") {

      set $script     $1;

      set $path_info  $2;

    }

    fastcgi_pass   unix:/run/php/php7.0-fpm.sock;

    fastcgi_index  index.php;

    fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;

    fastcgi_param  PATH_INFO          $path_info;

    include        fastcgi_params;

  }

  location ~ .*\.(gif|jpg|jpeg|png|bmp|swf)$ {

    expires      1d;

  }

  location ~ .*\.(js|css)?$ {

    expires      12h;

  }

  }

网站栏目:Thinkphp框架的网站lnmp无法页面跳转配置
网页地址:https://www.cdcxhl.com/article38/jgpipp.html

成都网站建设公司_创新互联,为您提供品牌网站设计网站导航ChatGPT网站维护云服务器网站改版

广告

声明:本网站发布的内容(图片、视频和文字)以用户投稿、用户转载内容为主,如果涉及侵权请尽快告知,我们将会在第一时间删除。文章观点不代表本网站立场,如需处理请联系客服。电话:028-86922220;邮箱:631063699@qq.com。内容未经允许不得转载,或转载时需注明来源: 创新互联

成都做网站