How does Magento customize the 404 page?

Source: Internet
Author: User
: This article mainly introduces how Magento customize the 404 page ?, If you are interested in the PHP Tutorial, refer. Magento modify page 404

Magento has a default 404 page. what should I do if I want to customize a 404 page?

Method 1

First, let's look at the default 404 page:

1. in the CMS section of Magento, you can define it to change the error page and log on to admin-> CMS-> Pages in the background:

2. open the 404 Not Found page and click Content on the left side to view details on the 404 page:

3. Now Let's redefine the 404 page. for example, enter the following code:

D'oh! That page can't be found.

Don't get angry, and don't cry. Let us take that burden. It's not your fault. No, really, listen to me. It's not your fault. We have a 24 hour hotline to deal with things just like this. Okay, its not really a hotline, its really just some encouraging words to keep trying, but hotline sounds so much .

Sorry but the page you are looking for cannot be found. If you're in denial and think this is a conspiracy that cannot possibly be true,

Perhaps you are here because:
  • The page has moved
  • The page is no longer exists
  • You were looking for your puppy and got lost
  • You like 404 pages
What can you do?
Have no fear, help is near! There are many ways you can get back on track with Magento Demo Store.
  • Go back to the previous page.
  • CMS and Design 30
  • Use the search bar at the top of the page to search for your products.
  • Follow these links to get you back on track!
    Store Home
    My Account

4. click save page and open it again. The page 404 has changed.

Method 2

Method 1: modify the configuration in the background. In addition, you need to know that you can modify the 404 page or the template.

1. First, you must change the status of 404 Not Found in CMS to disable.

2. find the no-route.phtml page, path to app/design/frontend/base/default/
Template/cms/default/no-route.phtml, open, you will see the following code:

There was no 404 CMS page configured or found.

3. open the front-end page again to check whether it is consistent with the above code. the front-end page is:

4. you can modify the 404 page by modifying the template file.

The above describes how Magento can customize the 404 page ?, Including some content, hope to be helpful to friends who are interested in PHP tutorials.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.