The 404 page is now at midnight 01:39. Here we want to popularize 404 public welfare activities. When the website you are visiting has a problem or the user tries to access a non-existent page, the server (nginx) will return an error message with the Status Code 404, the corresponding page is the 404 page. The default 404 content of nginx server is 404 not found! 404 public welfare I think that when I encounter a 404 error, I should not simply present an insignificant page. It happened that QQ had engaged in 404 public welfare activities, and I am happy to help my children go home. Sometimes the technical progress of a person makes himself happy, but the true public welfare will make people satisfied. Add a 404 public welfare link: (1)download the 404.html page from the 404public welfare chain
(2) Change the website virtual host configuration file that nginx listens to, and add it in the server definition area.
- Fastcgi_intercept_errors on;
- Error_page 404 =/404.html;
- Editing the location definition area supports 404 page rendering.
#404 public welfare fastcgi_intercept_errors on; error_page 404 =/404.html; location =/404.html {root/public_404/html ;}
(3) Reload nginx good contact support 404 public welfare good contact and official website good contact product website
Parameter description (1) fastcgi_intercept_errors: This directive
Determines whether or not to transfer 4xx and 5xx errors back to the client or to allow nginx to answer with Directive error_page.
(2) error_page:The directive specifies the URI
That will be shown for the errors indicated.