Author |
Topic  |
|
LadyM
ECT Moderator
1573 Posts |
Posted - 04/23/2020 : 10:58:53
|
When changing cart styles - colors etc. in ectcart.css, all changes will be overwritten in an update. So it was suggested to make a new style sheet and attach that. My question is: should the new one be a copy of ectcart.css with the changes made and a new name, or should it contain ONLY the changes and the new name? |
|
1818charlie
Ecommerce Template Expert
United Kingdom
678 Posts |
Posted - 04/23/2020 : 11:18:54
|
Hi LadyM
The changes to the css rules in the ectcart.css file only need adding in to your existing style.css file, no real need for another css file.
Steve Bolton, Lancashire, UK
Remember - Any edits to the ectcart.css file will be overwritten by updater's. ALL edits to ectcart.css rules should be placed in your style.css file
|
Edited by - 1818charlie on 04/23/2020 11:19:40 |
 |
|
Phil
ECT Moderator
United Kingdom
7209 Posts |
Posted - 04/23/2020 : 11:39:49
|
Hi LadyM
Just one more addition to what Steve has suggested. Make sure the call to the ectcart.css file comes before your existing style.css line like this:
<link href="css/ectcart.css" rel="stylesheet" type="text/css" /> <link href="css/style.css" rel="stylesheet" type="text/css" />
Then any changes you make just add them to the style.css file so it overrides the ectcart.css file

* Database Migrations and Conversions* * ASP to PHP Cart Conversions* *Contact Us* *Buy The PHP Capture Card Plugin* *Rate Our Services/View Our Feedback* |
 |
|
dbdave
ECT Moderator
USA
8885 Posts |
Posted - 04/23/2020 : 12:04:22
|
Hi LadyM, in addition to the other great replies, I wanted to add a little info on how that works.
When it comes to the stylesheets attached to a page, the rule that will take effect is the last one the browser receives.
This is why, as Phil mentions, you want the ectcart.css file first, then your stylesheet called after that. Anything you want to override in the ectcart.css file, you just add to your css file with the changes. Then it will take precedence and no need to edit the ectcart.css file with each update.
|
 |
|
LadyM
ECT Moderator
1573 Posts |
Posted - 04/23/2020 : 12:58:24
|
Thanks everyone, it's exactly what I needed to know. |
 |
|
|
Topic  |
|