Ecommerce software home
Shopping Cart Software Forum for Ecommerce Templates
Home | Profile | Register | Active Topics | Members | Search | FAQ
Save Password
Forgot your Password?

Find us on Facebook Follow us on Twitter View our YouTube channel
Search our site

 All Forums
 CSS and Responsive Designs
 Best practice?
 New Topic  Reply to Topic
 Printer Friendly
Author  Topic   

ECT Moderator

1608 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?

ECT Moderator

United Kingdom
829 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.

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

ECT Moderator

United Kingdom
7353 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*

ECT Moderator

9350 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.

ECT Moderator

1608 Posts

Posted - 04/23/2020 :  12:58:24  
Thanks everyone, it's exactly what I needed to know.
 New Topic  Reply to Topic
 Printer Friendly
Jump To:
Shopping Cart Software Forum for Ecommerce Templates © 2002-2020
This page was generated in 0.02 seconds. Snitz Forums 2000