Shilon Posted July 15, 2009 Report Share Posted July 15, 2009 I would like to know, when you have a big website to make, do you create a main css with the basics for all pages, and another css for each another page, or do you put everything on one only css file? Quote Link to comment Share on other sites More sharing options...
Wickham Posted July 15, 2009 Report Share Posted July 15, 2009 It depends, there isn't really any specific way. If it's just a few styles that apply to a non-standard page you could leave them in the main stylesheet with clear comments inside /*...*/ tags that they are for a non-standard page perhaps grouped together at the bottom of the stylesheet, but they would have to have a different id or class. If you want to use the same id or class name for a non-standard page but with a different style, you must have it coded separately. You should have a stylesheet which applies to most pages, assuming that your site has a consistent design, which it should. Even then, it's often recommended to have a different stylesheet for a complicated menu or a form. Then if only one page needs different styles, if it's only one or two items with the same style names as in the main stylesheet like #sidebar then you can put the styles in a head section style tag after the main stylesheet link to be processed last. Make a different stylesheet if you have more than one non-standard page which can include only the different styles and put the stylesheet link just after the main stylesheet link to be processed last. I hope that helps. Quote Link to comment Share on other sites More sharing options...
Shilon Posted July 15, 2009 Author Report Share Posted July 15, 2009 Im using all on the same css file, its getting a little complicated, and I only made 3 pages, thats why I asked. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.