Why shouldn't I copy and paste the original stylesheet into editor?
-
I’m learning a lot by looking at the original theme stylesheet, but It seems easier to cut and paste the whole stylesheet into editor and make changes that way. For example, I can search for all of one color and replace it with another by simply using my browser’s cntrl+f option. But it says”Use this as a reference and do not copy and paste all of it into the CSS Editor.”
I assume there’s a reason it says this, but what is it?
The blog I need help with is: (visible only to logged in users)
-
Reasons are more than one. See here:
http://csswiz.wordpress.com/2009/10/15/if-you-have-the-wp-com-css-upgrade/ -
The original style sheet is scanned then your changes are scanned and last scanned rules.
If you have the whole sheet scanned a second time that is extra overhead and slows your load time down –
-
To add a detail to what the article I linked to says and to what auxclass pointed out: both unnecessarily repeated code and unnecessarily long loading time are factors taken into account by Google for page ranking.
-
Cool; thanks very much. What if I clicked the “Don’t use Chunk’s CSS, and replace everything with my own CSS” option? Would that solve the repeated code issue?
-
It will solve the repeated code issue but
a) it won’t help you keep track of what the original is and what your changes are.
b) relative paths to background images will be broken.
Not recommended if you’re not an expert. -
I feel like I could just save a document of the original stylesheet to solve problem “a”, but considering I’m not sure what you mean by “b”, I think I should take your advice. I’m definitely not an expert.
-
An absolute path URL would be the full URL starting with http:// .
A relative path URL means relative to the document the URL is called in.
Absolute: http://site.com/wp-content/themes/eveningshade/images/logo-default.png
Relative: images/logo-default.png (the document calling that image is in the “eveningshade” subdirectory.
- The topic ‘Why shouldn't I copy and paste the original stylesheet into editor?’ is closed to new replies.