Define Main Page Content Also Showing Up in Category Pages
URL : www.NortheastTroller.com
ZC Version 1.5.8
PHP : 7.4.33
Bootstrap Template
Define main page content is also showing up in category pages.
I looked at this old thread - https://www.zen-cart.com/showthread....category-pages but no avail.
Help?
Re: Define Main Page Content Also Showing Up in Category Pages
Could very well be your old version of bootstrap. A look at your site's page source shows 3.1.2 with 3.5.0 being current.
Re: Define Main Page Content Also Showing Up in Category Pages
Modify your template files (tpl_index_categories.php, tpl_index_default.php) to wrap the inclusion of the define page content
require($define_page);
in a check to see if it's the home page:
if ($this_is_home_page) {
... // code for pulling in define page
}
Re: Define Main Page Content Also Showing Up in Category Pages
Quote:
Originally Posted by
swguy
Modify your template files (tpl_index_categories.php, tpl_index_default.php) to wrap the inclusion of the define page content
require($define_page);
in a check to see if it's the home page:
if ($this_is_home_page) {
... // code for pulling in define page
}
Oddly, no string is found in tpl_index_categories.php , and when I add the
if ($this_is_home_page) {
... // code for pulling in define page
}
On tpl_index_default.php it removes all content from that define area but still shows it on the category page.
I'm so confused!
Re: Define Main Page Content Also Showing Up in Category Pages
Figured it out. in tpl_index_categories what originally read as
Code:
<?php
/**
* require the html_define for the index/categories page
*/
require $define_page;
?>
Needed to have the addition of // before the require, to actually be:
Code:
<?php
/**
* require the html_define for the index/categories page
*/
// require $define_page;
?>
Now, the define shows up on the main page, where it should be. And not in the categories.