Welcome! Log In Create A New Profile

Advanced

Nginx 404 redirection to error page

Dhanushka Parakrama
April 08, 2022 08:18AM
Hi All

I have simple drupal site running and i wanted to redirect 404 pages to a
error page , So i have following configuration in place

error_page 404 https://example.com/page-not-found;

when it try to access non existing page such as https://example.com/abc
, then from nginx page correctly get redirect to the
*https://example.com/page-not-found
https://example.com/page-not-found*

But when i try to access non non-existing page ( with extension ) such as
https://example.com/*abc.js * it does not get redirected to the
*https://example.com/page-not-found
https://example.com/page-not-found *page .

So is there any way to fix this issue? , please advice

Thank You
_______________________________________________
nginx mailing list -- nginx@nginx.org
To unsubscribe send an email to nginx-leave@nginx.org
Subject Author Posted

Nginx 404 redirection to error page

Dhanushka Parakrama April 08, 2022 08:18AM

Re: Nginx 404 redirection to error page

Francis Daly April 09, 2022 02:34AM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 124
Record Number of Users: 6 on February 13, 2018
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready