TP5部署服務器只能打開首頁其他頁面全是404
問題描述
nginx.conf
server { listen80; server_name cy.280878.com; root/home/www/cy.280878.com; indexindex.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$fastcgi_path_info; fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; include/etc/nginx/fastcgi_params;} }
.htaccess
<IfModule mod_rewrite.c>Options +FollowSymlinks -MultiviewsRewriteEngine onRewriteCond %{REQUEST_FILENAME} !-dRewriteCond %{REQUEST_FILENAME} !-fRewriteRule ^(.*)$ index.php?/$1 [QSA,PT,L]</IfModule>
首頁:http://cy.280878.com/newswork/
404頁面:http://cy.280878.com/newswork/details/index.html?id=4
問題解答
回答1:是不是圖片路徑傳的不對
相關文章:
1. windows誤人子弟啊2. php傳對應的id值為什么傳不了啊有木有大神會的看我下方截圖3. python - linux 下用wsgifunc 運行web.py該如何修改代碼4. python - oslo_config5. 關于mysql聯合查詢一對多的顯示結果問題6. 實現bing搜索工具urlAPI提交7. 冒昧問一下,我這php代碼哪里出錯了???8. mysql優化 - MySQL如何為配置表建立索引?9. MySQL主鍵沖突時的更新操作和替換操作在功能上有什么差別(如圖)10. 數據庫 - Mysql的存儲過程真的是個坑!求助下面的存儲過程哪里錯啦,實在是找不到哪里的問題了。
