nginx如何實現404狀態返回 200隱藏URL

以http://WWW.cnblogs.COM爲例:

server
       {
               listen       80;
               server_name  www.cnblogs.com;
               charset gb2312;
               index index.php index.html;
               root   /data/www/wwwroot/linuxtone/www.cnblogs.com;
               error_page 404 =200 /.404.jpg;
//注:上傳一個404.jpg文件到www.cnblogs.com的根目錄,並更名爲.404.jpgphp

或者error_page 404 =200 /.404.html;html

打開一個頁面linux

相關文章
相關標籤/搜索