Handle 404 flow with EE


#1

Hi there,

I was wondering how the 404 are handled with EE?

Right now I some 404 that I want to redirect to the homepage with a WP plugin, but nothing work and always get the nginx 404 error message.

So what is the flow for 404? How to do redirect to a special page?

Thanks


#2

Just up this topic as I am still waiting for answer. I’m sure this is very basic (can do with Apache) but struggling to understand with nginx how it is working.


#3

You use the error_page property in the nginx config. Put this within the server block.

For example, if you intend to set the 404 error page to /404.html, use

error_page 404 /404.html;

Setting the 500 error page to /500.html is just as easy as:

error_page 500 /500.html;

#4

Hi Grex,

Thanks, you answered part of the question - which is already great for my knowledge.

But maybe I wasn’t clear, so here example:

How to redirect a http://www.domain.com/this_page_does_not_exist_anymore to http://www.domain.com/ ?

This is because Google Webmaster found a lot of 404 and I need to remap them to the correct pages. I tried with htaccess but not working :frowning:


#5

Is this a WP website?


#6

Hi,

Yes this is wordpress sites.

I found a plugin that actually work fine:

Thanks


#7