SitePoint Sponsor

User Tag List

Results 1 to 10 of 10
  1. #1
    SitePoint Zealot
    Join Date
    Nov 2012
    Posts
    117
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)

    Linking multiple stylesheets

    Hi there,

    I am using a Dedicated Server. In the web-hosting side, I have folders arranged like so.

    Code:
    html
            forum
                files
            images
                files
            Equinox
                index.php
                header.php
                footer.php
            style
                style.css
            mc-multiplayer
                style
                    style.css
                index.php
                header.php
                footer.php
    I am trying to get the index.php of mc-multiplayer to link to the css file in mc-multiplayer, but no matter what it keeps going to the style.css file in the html folder.
    Last edited by ralph.m; Jan 9, 2013 at 03:31. Reason: added code tags to preserve formatting

  2. #2
    It's all Geek to me silver trophybronze trophy
    ralph.m's Avatar
    Join Date
    Mar 2009
    Location
    Melbourne, AU
    Posts
    24,319
    Mentioned
    462 Post(s)
    Tagged
    8 Thread(s)
    The link on the /mc-multiplayer/index.php page would need to look either like this:

    Code:
    <link rel="stylesheet" media="screen,projection,tv" href="style/style.css">
    or this:

    Code:
    <link rel="stylesheet" media="screen,projection,tv" href="/mc-multiplayer/style/style.css">

  3. #3
    SitePoint Zealot
    Join Date
    Nov 2012
    Posts
    117
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    Thanks a lot for help

  4. #4
    It's all Geek to me silver trophybronze trophy
    ralph.m's Avatar
    Join Date
    Mar 2009
    Location
    Melbourne, AU
    Posts
    24,319
    Mentioned
    462 Post(s)
    Tagged
    8 Thread(s)
    You're welcome.

    Let us know if you need any more help. Actually, though, my advice would be to place all your style sheets into one folder for easy reference ... and I wouldn't recommend having too many. (I rarely have more than one or two.)

  5. #5
    SitePoint Member joshuagnizak's Avatar
    Join Date
    Jan 2013
    Location
    Berlin
    Posts
    10
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by ralph.m View Post
    You're welcome.

    Let us know if you need any more help. Actually, though, my advice would be to place all your style sheets into one folder for easy reference ... and I wouldn't recommend having too many. (I rarely have more than one or two.)
    I've never used more than 2 style sheets. At what point do you recognize a slowdown?

  6. #6
    It's all Geek to me silver trophybronze trophy
    ralph.m's Avatar
    Join Date
    Mar 2009
    Location
    Melbourne, AU
    Posts
    24,319
    Mentioned
    462 Post(s)
    Tagged
    8 Thread(s)
    Quote Originally Posted by joshuagnizak View Post
    At what point do you recognize a slowdown?
    No necessarily ever ... but it seems neater to me not to use too many, and the fewer calls to the server, the better in general. I doesn't take long to load a style sheet, and then it's cached for the other pages.

  7. #7
    SitePoint Member joshuagnizak's Avatar
    Join Date
    Jan 2013
    Location
    Berlin
    Posts
    10
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    True. Iv'e noticed some 'webmaster tools' recommend minimizing css too. It must be such a minimal difference, but every drop counts.

  8. #8
    It's all Geek to me silver trophybronze trophy
    ralph.m's Avatar
    Join Date
    Mar 2009
    Location
    Melbourne, AU
    Posts
    24,319
    Mentioned
    462 Post(s)
    Tagged
    8 Thread(s)
    Quote Originally Posted by joshuagnizak View Post
    True. Iv'e noticed some 'webmaster tools' recommend minimizing css too. It must be such a minimal difference, but every drop counts.
    Indeed.

    And welcome to the forums, by the way.

  9. #9
    SitePoint Member joshuagnizak's Avatar
    Join Date
    Jan 2013
    Location
    Berlin
    Posts
    10
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Thanks

  10. #10
    SitePoint Member
    Join Date
    Jan 2013
    Posts
    1
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I'm making a website with a very large css, and of course all does not apply for every page. Would it be good to split into like 5 ccs's? Some pages could use one, others maybe all five. If I do that, what's the best way, link all sheets used in the html in the head section, or link the 'main' css, and put in that one load 'css2, css3...'


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
  •