Der TP5-Bereitstellungsserver kann nur die Homepage öffnen und andere Seiten sind alle 404
燕浮生若梦
燕浮生若梦 2019-09-18 14:16:06
0
2
1232

nginx.conf

server
  {
   listen        80;
   servername cy.280878.com;
   root        /home/www/cy.280878.com;
   index      index.php index1.php index.htm index.html;



   #location / {
   #        if ( -f $request_filename) {
   #          break;
   #        }
   #      if ( !-e. $request_filename ) {
   #            rewrite ^(.*)$ /index.php/ $1 last;
   #            break;
   #       }
   #    }


       location ~ .+.php($|/) {
           #fastcgi_pass. unix:/dev/shm /php-cgi.sock;
           fastcgi_pass     127.0.0.1: 9000;
           fastcgi_split_path_info ^((?U).+.php)(/?.+)$;
           fastcgi_param PATH_INFO $fastcgi_path_info;
           fastcgi_param PATH_TRANSLATED. $document_root$fast cgi_path_info;
           fastcgi_param    SCRIPT_FILENAME    $document_root$fastcgi_script_name;
           include        /etc/ nginx/fastcgi_params;

       }

  }

.htaccess

<IfModule mod_rewrite.c>
Options +FollowSymlinks -Multiviews
RewriteEngine on
RewriteCond. %{REQUEST_FILENAME } !-d
RewriteCond %{REQUEST_FILENAME} !- f
RewriteRule ^(.*)$ index.php?/$1 [QSA,PT,L]
</IfModule>


首页:http://cy.280878.com/newswork/

404页面:http://cy.280878.com/newswork/details/index.html?id=4

燕浮生若梦
燕浮生若梦

Antworte allen(1)
(O_O)

是不是图片路径传的不对

  • Antwort 已解决,重定向位置路径的问题..还有index.php做了目录限制...
    燕浮生若梦 Autor 2019-09-20 15:55:01
Beliebte Tutorials
Mehr>
Neueste Downloads
Mehr>
Web-Effekte
Quellcode der Website
Website-Materialien
Frontend-Vorlage
Über uns Haftungsausschluss Sitemap
Chinesische PHP-Website:Online-PHP-Schulung für das Gemeinwohl,Helfen Sie PHP-Lernenden, sich schnell weiterzuentwickeln!