Jump to content

Adding Tabs to Home Page


Recommended Posts

I have made my own tab and most of it works but I cannot find where to add the jquery link as every time I click it it does not switch to page. So on behalf of all us users can someone please give a tutorial on this as it seems there is little on the home page tab addition.

 

I hope someone can either message me with the information so I can make the tutorial, or make one themselves as this would help many of us to generate more sales and the ability to buy or pay for other modules and themes.

 

 

 

Thanks,

 

William

Shop Save N Earn

http://www.shopsavenearn.com

Link to comment
Share on other sites

I use 1.5 theme on my live website, although I use 1.6 of the same that is upgraded to 1.6, all of which has upgraded flawlessly I might add for my testing site which is on the same server and based off of the default bootstrap theme.

 

I have everything working except when I click the tab the content does not show.

Link to comment
Share on other sites

Yes thank you for your help.

 

 

By chance, can I call a front controller class from the module as I cannot populate smarty using the same Product::PricesDrop statement used in the controller as it errors. I did create a new controler but not sure how to call it to populate the smarty.

Edited by ShopSaveNEarn (see edit history)
Link to comment
Share on other sites

Why cant I put this

  $this->productSort();
        $nbProducts = Product::getPricesDrop($this->context->language->id, null, null, true);
        $this->pagination($nbProducts);
        $products = Product::getPricesDrop($this->context->language->id, (int)$this->p - 1, (int)$this->n, false, $this->orderBy, $this->orderWay);
        $this->addColorsToProductList($products); 

in my module page as the;

$this->productSort();
 $this->pagination($nbProducts);
$this->addColorsToProductList($products); 

and the bolded parts also error

 

 

$this->p - 1, (int)$this->n, false, $this->orderBy, $this->orderWay)

 

 

However, I must have the information the PricesDrop controller generates to run the prices drop products

Link to comment
Share on other sites

okay while testing and viewing everything it seems that the actual page for specials is no longer working. So my question is, "

 

How come Product::getPricesDrop works but when adding my own controller the Product::getSpecialsTabContent will not?

 

Also why does

$specials = Product::getPricesDrop($this->context->language->id, (int) 1,(int) 12, false);

make the Specials page not work?

Link to comment
Share on other sites

Somehow I fixed my tabs not working by ensuring the module hooks were in displayHomeContentTabs, then in BO Preferences > Themes > Clicked EDIT on my theme, made a change (any change) then saved.
Seems to have needed some SAVE code that the themes page offers. Dont know, but its now working.

Link to comment
Share on other sites

  • 3 months later...
×
×
  • Create New...