How do OpenCart Layouts Work?

Posted by Paul on October 14, 2016

Once you know how it's actually very easy to adjust the layout of various OpenCart pages to move things around and remove or add items. Here's a quick overview of how it works.

Let's say we want to do a few things to the category page:

  1. Remove the category nav in the left column
  2. Remove the banner below the left nav
  3. Add a slideshow
  4. Add featured products

So to start with, the category page looks like this:

 

category-page.jpg

 

To remove the category list and banner go Design > Layouts and edit the one called Category:

 

design-layouts-category.jpg

 

Remove the Modules called Category and Banner > Category:

 

design-layouts-category-edit.jpg

 

Once you click the blue Save icon at the top right, those will instantly be removed from the page:

 

category-page-no-left-col.png

 

Now, in the Design > Layouts > Category edit page, add a new module. A slideshow is already made for the Home Page (in Extensions > Modules) so we can add that one:

 

design-layouts-category-add-slideshow.jpg

 

You can also add the featured products this way. If you wanted to have different featured products on the Category page, you could create these under Extensions > Modules and click the + next to Featured.

 

design-layouts-category-add-featured.jpg

 

Once that's saved with the blue Save icon, we can refresh the Category page and see it's now how we wanted:

 

category-page-no-left-col-featured-slideshow.png

 

Any questions? Let us know in the comments ...

blog comments powered by Disqus