: Zen Cart - different banners for each page I have a zen cart shop with a costumized template and for now there is a slideshow gallery under the header. I need to keep this gallery for the
I have a zen cart shop with a costumized template and for now there is a slideshow gallery under the header. I need to keep this gallery for the first page only, but on all the other pages there should be distinct banners instead of the gallery, relative to the visited page. e.g. on the "about us" page there should be banner_aboutus.ext, contact => banner_contact.ext and so on. Please help me do this.
Thanks in advance
More posts by @Si4351233
1 Comments
Sorted by latest first Latest Oldest Best
I've done it the hard way with php - I'm lucky that zen cart allows php in templates...
I used conditions with 3 vars: $_GET['main_page'], $_GET['cPath'] and $_GET['id'] and depending on their value I inserted the content I need as follows:
if($_GET['main_page']=='index' && !$_GET['cPath']){ // this condition is met only on the first page
// slideshow
}
elseif($_GET['main_page']=='page' && $_GET['id']==1){
// banner
} // and so on
Terms of Use Create Support ticket Your support tickets Stock Market News! © vmapp.org2024 All Rights reserved.