Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 133723
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 11, 20262026-05-11T06:29:03+00:00 2026-05-11T06:29:03+00:00

I do a lot of custom applications at work. I’m trying to define some

  • 0

I do a lot of custom applications at work. I’m trying to define some standards for new applications. Something a little like Elements.

CSS: How do you organize the style sheets? Should I have one base style sheet for the whole site and one for each individual page for customizations? Should I have another for print styles? I’ve heard that linking more files takes more time for the browser to retrieve them. (More objects per page…also a problem with lots of javascript files or images) … How many is is too many? Do you heavily comment your CSS? Provide any nested structure? Alphabetize within elements? Do I need a reset? What about imports? And typography?

Javascript: Basically the same question. Javascript files…Should I include one or two nice libraries (JQuery and Prototype, for example) and then have another included for each page? Now I’m suddenly including 5 or 6 CSS and JS files…

Directory Structure: How do you organize a site? Currently, I use something like

/CSS          ... For CSS files /JS           ... For javascript files /INC          ... For private code includes /ASSETS/IMG   ... For images /ASSETS/AU    ... For audio /ASSETS/SWF   ... For Flash 

Also, any other tips would be welcome. Thanks!!

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. 2026-05-11T06:29:03+00:00Added an answer on May 11, 2026 at 6:29 am

    Should I have one base style sheet for the whole site and one for each individual page for customizations?

    Be pragmatic. If you have few enough rules that you can organise them all in one file and retain an oversight of what does what, do that. If you have a significant number of rules that only apply to certain sections or individual pages in your site, by all means break them out into their own sub-stylesheets, but don’t feel the need to create a separate stylesheet for every single page even when it only contains two rules. Add a page-specific class or id to <body> so you can pick out single pages from a shared stylesheet should you need to.

    The separation of styles into stylesheets is for your benefit as an author, so do what you find easiest to manage. For a complicated site that’ll probably be more than one CSS file, but it’s not going to be dozens.

    Should I have another for print styles?

    Generally yes. Whilst you can embed print styles inside another stylesheet using an @media rule, this has traditionally been buggy, so putting the media in the <link> tag is usually easiest. In any case print stylesheets are often so different from their screen counterparts that it just makes sense to keep their rules separate.

    I’ve heard that linking more files takes more time for the browser to retrieve them.

    Yes, but this effect is often overstated. HTTP/1.1 reduces the per-request latency by keeping connections between the client and server alive, which is a strong mitigation.

    How many is is too many?

    Enough that you’re extremely unlikely to have that many stylesheets. Scripts can be a problem if you’re using the kind of framework that demands one script file per class, but otherwise are generally OK. It’s more commonly problematic with lots of small images.

    Do you heavily comment your CSS?

    Light commenting usually should be enough. CSS’s declarative rule style doesn’t usually get complicated enough to need the in-depth explanations code can demand. In particular though, document anything counterintuitive like browser-specific hacks.

    Alphabetize within elements?

    Not unless that makes it easier for you to manage. Usually it wouldn’t, you’d try to group similar rules, or rules applying to similar groups of elements.

    Do I need a reset?

    A full reset? Not if you know what you’re doing and can select the particular problematic defaults you want to reset.

    Should I include one or two nice libraries (JQuery and Prototype, for example)

    Don’t include more than one framework unless you absolutely have to.

    and then have another included for each page?

    If each page has particular custom behaviour you could. But that doesn’t usually happen. If you make progressive-enhancement behaviour scripts that bind to eg. class names, you can include the script for each behaviour on each page that uses it, then let it find the elements to bind to automatically.

    Directory Structure: How do you organize a site?

    Personally, for my Python/WSGI applications:

    appfolder     application.py       - main WSGI entry point and control/configuration script     data                 - run-time writable application file store         private          - files not available through the web server         public           - mounted as a virtual directory on the web server     logs                 - access, error, application log files     system               - all the static application code and data         htdocs           - web server root folder             file         - static servable files             img          - static images             script       - JavaScript             style        - CSS         lib              - Python modules used by site             appmodule    - main application code package         templates        - HTML page templates             mail         - mail text templates 

    It’s important for me to keep the ‘data’ in a separate place (with separate permissions) to the application in ‘system’. You need to be able to swap out the ‘system’ folder to upgrade the application, without having to worry that there are uploaded images in htdocs/img you have to worry about keeping.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I currently work at a company that has a lot of custom applications that
Our applications use lot of custom built and third party libraries and right now
We have a lot of web applications, configured using custom sections (in their web.config
i'am writing some swing applications(not rich clients, running standalone) with a lot of domain
I'm developing a lot of RadiantCMS applications, and this CMS uses custom radiant tags
I get a lot of requests in my application to allow for custom icons
I execute a lot of custom actions in my InnoSetup script in the CurStepChanged(ssPostInstall)
Lately I've been doing a lot of custom styling in SharePoint by modifying the
I have a lot of strings containing custom tags: hello {RT|12} world {RT|465} this
I've been creating a lot of my own custom attributes in my XHTML documents

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.