ExpressionEngine CMS
Open, Free, Amazing

Thread

This is an archived forum and the content is probably no longer relevant, but is provided here for posterity.

The active forums are here.

Twitter Bootstrap CSS linking via {stylesheet} vs. {path} vs. static URL

December 27, 2013 9:15am

Subscribe [1]
  • #1 / Dec 27, 2013 9:15am

    Datenliebe

    8 posts

    Hi folks,

    I am building a clickdummy using Twitter’s Bootstrap framework.

    In the example on http://wichtel.moloma.de/standorte I use

    <link href="{path='embed/css_bootstrap'}" rel="stylesheet">

    for linking to the bootstrap stylesheet. Bootstrap is stored as a CSS template in a separate template group called “embed”.

    Does not work.

    The layout is not rendered properly although certain styles from the CSS seem to work just fine (font styles, colours, etc.).

    Linking to the stylesheet directly (identical bootstrap CSS file stored in a separate folder) via

    <link href="{site_url}css/bootstrap.min.css" rel="stylesheet">

    works fine as you can see on http://wichtel.moloma.de

    The rest of the HTML is 100% identical on each page.

    I can live with the second method. Nevertheless, what is wrong with the {stylesheet} and/or {path} method? Any mistake I just don’t see?

    Thank you!
    Olli

  • #2 / Dec 27, 2013 3:14pm

    iDzine

    2 posts

    Why you don’t use {stylesheet='embed/css_bootstrap'}
    See doc for more info:
    http://ellislab.com/expressionengine/user-guide/templates/globals/stylesheet.html

  • #3 / Dec 27, 2013 3:24pm

    Datenliebe

    8 posts

    Sorry, forgot to mention that {stylesheet} leads to exactly the same result: does not work, too.

  • #4 / Dec 27, 2013 3:32pm

    iDzine

    2 posts

    K,

    You sure that the embedded version is an exact copy?
    The stylesheet (http://wichtel.moloma.de/embed/css_bootstrap) itself stops if rendered at: fieldset[disabled] .btn-link{

    As the working one ends at: print{display:none!important}}

    Maybe that’s the fault?

  • #5 / Dec 31, 2013 11:41am

    Datenliebe

    8 posts

    That’s it, thank you!

    For some reason the minified CSS is cut off at fieldset[disabled] .btn-link{. The non-minified CSS works just fine.

.(JavaScript must be enabled to view this email address)

ExpressionEngine News!

#eecms, #events, #releases