Showcasing a representation of your store’s products on the ‘Page Not Found’ page can save a visitor from doing a quick u-turn away from your site, instead inviting them into your store to explore further.
To display your featured products on the ‘Page Not Found’ page:
- Open the tpl_page_not_found_default.php file located in the includes/templates/template_default/templates/ directory.
- Find the section of code that calls the ‘page not found’ define text:
<div id="pageNotFoundMainContent"> <?php /** * require the html_define for the page_not_found page */ require($define_page); ?> </div> <?php } ?>
- Immediately following, insert this block of code to call the Featured Products Center Box:
<?php /** * display the Featured Products Center Box */ ?> <?php require($template->get_template_dir('tpl_modules_featured_products.php',DIR_WS_TEMPLATE, $current_page_base,'templates'). '/tpl_modules_featured_products.php'); ?> - Save the modified tpl_page_not_found_default.php file to your override folder. This will be includes/templates/CUSTOM/templates/ where CUSTOM represents the name of your current template folder.
So, instead of this:

the Zen Cart ‘Page Not Found’ page now also includes the Featured Products center box:

|
|||||||


