Friday, May 25, 2012

styling openCart

(written in reference to version 1.5.2.1)

Theme Location

Theme stylesheets are found in the subdirectory ‘/catalog/view/theme’ within the openCart folder on your site. 

 

Editing Existing Themes

To edit a pre-existing theme, go to the theme’s location eg ‘/catalog/view/theme/default’ and go to the folder ‘stylesheet’ and then open ‘stylesheet.css’.  Once the file has been edited and re-uploaded, the changes you make be will be applied to your shop’s design.

If you have no experience with CSS (Cascade Style Sheets) check out CSS Basics and the w3schools site section on CSS, as you will need to understand how stylesheets work to start making changes!

 

Creating a New Theme

To create a new theme, create a new folder, with the required theme name, and copy over the image and stylesheet folders from the default template.  Also, create a folder ‘template’ with a folder within that called ‘common’.  In that, copy over the header.tpl file from the same directory in the default theme folder.

Edit the header.tpl file and replace every instance of ‘default’ with the name of your theme (what

Now, go into the admin panel eg. http://www.myshop.com/shop/admin and then go to system > settings from the navigation bar and click ‘Edit’ next to the shop that you want to theme.

From here, choose the ‘Store’ tab, and click the drop down box next to where it says ‘Template’.  The name which you chose for the new theme should now appear here.  Select it and then click Save to update it.

 

Go back to your shop page (eg http://newshop.myshop.com) and refresh.  The default theme you will now be applied to the page!

See the Editing Existing Themes section to get editing themes.