I've learned how to override certain templates by creating a directory of my own in catalog/view/theme --
Code: Select all
catalog/view/theme/default/
catalog/view/theme/my-theme/
However, I'm having difficulty overriding the default CSS file (catalog/view/theme/default/stylesheet/stylesheet.css). I thought that merely adding a stylesheet directory into my own theme directory and copying the default stylesheet into that directory, then editing it, would override the default CSS stylesheet, but apparently not.
/catalog/view/theme/my-theme/stylesheet/stylesheet.css seems to be ignored.
Is there any documentation about how to override OpenCart's theme and CSS? I was unable to find any such information in the OpenCart documentation linked-to in the "Documentation" menu at the top of most OpenCart.com pages. Thank you.
---
UPDATE
I'll answer my own question, for anyone else who may be interested. The CSS stylesheet to be used with any particular theme is specied in the /catalog/view/theme/theme-name/template/common/header.tpl file.
So first one needs to make a directory in one's own theme folder called "common" --
Code: Select all
/catalog/view/theme/MY-THEME-NAME/common/
Code: Select all
/catalog/view/theme/MY-THEME-NAME/common/header.tpl
<link href="catalog/view/theme/default/stylesheet/stylesheet.css" rel="stylesheet">
and make it look like this instead--
<link href="catalog/view/theme/MY-THEME-NAME/stylesheet/stylesheet.css" rel="stylesheet">
Of course, substitute the actual name you have given the directory that contains your theme (instead of using "MY-THEME-NAME")
---