How do I redirect to eZ's standard 404 page from a template operator?

Author Message

Daniel Staver

Friday 10 September 2010 6:46:27 am

I want to make a template operator that generates a 404 response for a template and displays eZ's standard 404 page. How can I do this? I've figured out how to create the 404 header, but I don't know how to show the standard 404 page. Usually we override this to a custom template that fetches and article giving some helpful information to the user.

I want to use this operator to prevent google from indexing helper child nodes that are displayed as part of another template but have no full view themselves. Somehow google is picking up these nodes, even when there are no direct links to them.

Daniel Staver
http://daniel.staver.no

Jérôme Vieilledent

Friday 10 September 2010 7:27:03 am

Hi Daniel

What about embedding the error template :

{include uri="design:error/kernel/2.tpl"}

Gabriel Finkelstein

Friday 10 September 2010 12:11:36 pm

I think you don't need to show the 404 page. As long as you return a 404 error, Google won't index that page.

Powered by eZ Publish™ CMS Open Source Web Content Management. Copyright © 1999-2014 eZ Systems AS (except where otherwise noted). All rights reserved.