Book Image

OpenCart Theme and Module Development

By : Rupak Nepali
Book Image

OpenCart Theme and Module Development

By: Rupak Nepali

Overview of this book

Table of Contents (13 chapters)
OpenCart Theme and Module Development
Credits
About the Author
About the Reviewers
www.PacktPub.com
Preface
Index

The category page


In this section, we will describe the code of the category page.

Hover over Desktops, which shows a dropdown, and click on the See All Desktops category link in the top menu. You will see something like this:

Now go to catalog/view/theme/default/template and copy the product folder. Then go to catalog/view/theme/packttheme/template and paste the product folder there. We have done this because we are going to change some things in the product folder's files, such as category.tpl, product.tpl, search.tpl. You should always create a copy of the files to which you wish to make the changes. After creating the copy, open catalog/view/theme/packttheme/template/product/category.tpl. You will see the following code, which we will describe now:

<?php echo $header; ?><?php echo $column_left; ?><?php echo $column_right; ?>

As we've discussed already, <?php echo $header; ?> is used to show the header part, <?php echo $column_left; ?> is used to show the left...