Welcome our webmaster and SEO forum
Please enjoy the forum, contribute what you can, and wind up the Moderators!
Results 1 to 10 of 10

Thread: Multiple CSS Style Sheets?

  1. #1
    susapra is offline Junior Member
    Join Date
    Nov 2008
    Posts
    9

    Default Multiple CSS Style Sheets?

    I'm currently in the process of designing my first full fledged site. The one thing I'm struggling with is while I want the overall look and feel of the site to be the same, some of the inter-page layout needs to be different to accomdate the variety of content between pages.

    Is it acceptable to use two style sheets linked to one html page?

    Also, would changes made in the second linked sheet over rule the 1st page?

  2. #2
    smeagain is offline Distinguished Member
    Join Date
    Jan 2008
    Posts
    263

    Default

    It is common practice to use more than one external CSS File. For example one file for layout and positional control with the other one for text styling etc.

    CSS stands for "Cascading Style Sheets"
    The cascading bit is the equivalent of obeying the last order. With multiple external CSS files, if the same styling factor appears in more than one linked css file, the one from the linked file that appears last in the running order will be used.

    Document level CSS can be inserted within the head of the document itself to override the external styles, but must be inserted into the head of the document after the appearance of the linking to all the external CSS Files.

    The same cascading effect can be used to override a CSS File by placing a style specific to one HTML element usage in-line.

  3. #3
    Bagi Zoltán's Avatar
    Bagi Zoltán is offline Boss Cart consultant
    Join Date
    Feb 2007
    Location
    Veszprém, Hungary
    Posts
    1,225

    Default

    I think if the difference between the inner pages are only little, I would rather use inline style in order to avoid the loading increasement due to the plus http request.

  4. #4
    johnafrankllin's Avatar
    johnafrankllin is offline Senior Member
    Join Date
    Feb 2008
    Posts
    206

    Default

    If it is in minor proportion than it is better to define style on the page otherwise external css the the best option.
    Using two css files is not problematic only you have to take care of the class names should be different.

    Regards
    John

  5. #5
    myst729's Avatar
    myst729 is offline Junior Member
    Join Date
    Oct 2008
    Posts
    16

    Default

    Yes, it is. It's a good way to manage your code - different CSS file, different usage.

  6. #6
    anurdh65 is offline Junior Member
    Join Date
    May 2009
    Posts
    9

    Default

    Multiple Styles Will Cascade Into One

    Style sheets allow style information to be specified in many ways. Styles can be specified inside a single HTML element, inside the <head> element of an HTML page, or in an external CSS file. Even multiple external style sheets can be referenced inside a single HTML document.
    Cascading Order

    What style will be used when there is more than one style specified for an HTML element?

    Generally speaking we can say that all the styles will "cascade" into a new "virtual" style sheet by the following rules, where number four has the highest priority:

    1. Browser default
    2. External style sheet
    3. Internal style sheet (inside the <head> tag)
    4. Inline style (inside an HTML element)

    So, an inline style (inside an HTML element) has the highest priority, which means that it will override a style declared inside the <head> tag, in an external style sheet, or in a browser (a default value).

  7. #7
    norbertwarne is offline Junior Member
    Join Date
    Oct 2010
    Posts
    17

    Default

    It is common exercise to use more than one outside CSS File. For example one register for present and positional assure with the early one for text styling etc.

  8. #8
    damienb is offline Junior Member
    Join Date
    Oct 2010
    Posts
    10

    Default

    The external CSS file is the best option for me. And I don't think it will be a problem to use two or more CSS files for one page.
    Last edited by damienb; 11-18-2010 at 10:17 AM.

  9. #9
    moritz is offline Member
    Join Date
    Mar 2011
    Posts
    38

    Default

    Rattling simply, can we acquire quadruplex CSS stylesheets on the selfsame page. We requisite to use various stylesheets for a position we're processing and I counterfeit if we had them all in the stabilise directory, we can use them?

  10. #10
    misamisa is offline Junior Member
    Join Date
    May 2011
    Posts
    5

    Default

    If separating css style will be you comfort zone,then so be it. besides,lot of developer uses multiple css styles to avoid confusion of codes.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124