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.

Css Vs Css

April 04, 2009 8:44pm

Subscribe [3]
  • #1 / Apr 04, 2009 8:44pm

    stefaandk

    5 posts

    Hi,

    I had my site designed for me so not an expert here but I obviously don’t want to bother Luke with every little thing.

    I’m building a static page on my site and giving it some basic html formatting, but it pulls the css format from the main css for the site which is fine but not for this scenario.

    Bottom line is there an EE tag I could put somewhere that would ensure this page does not use the site’s CSS?

    Or if I specify my own would it override the built in, this doesn’t seem to work but that may be me lack of knowledge here still but I want to make sure that what I’m doing is not a waste of time.

    Thanks

  • #2 / Apr 04, 2009 9:44pm

    grrramps

    2219 posts

    Are you building a static page using EE? If so, find the <head> and take out the link to the site’s main CSS.

  • #3 / Apr 05, 2009 6:53pm

    mayest

    293 posts

    I create a variable in each template and then pass it to my .html_head_tag template like this:

    {assign_variable:my_stylesheet="embeds/new_css"}
    
    {embed="embeds/.html_head_tag" style="{my_stylesheet}"}

    In the .html_head_tag it sets the style sheet like this:

    <link rel='stylesheet' type='text/css' media='all' href="{stylesheet={embed:style}}" />

    This way I can use a different style sheet for every template if I wanted to. Of course, I set it up this way but I use the same CSS for everything. 😊 Still, I could change it if necessary.

    You could do something similar using a custom field that specifies the style sheet to use for each weblog entry.

  • #4 / Apr 05, 2009 9:35pm

    grantmx

    1439 posts

    I agree with Grumps and Mayest.  It all depends on your setup.  Can you post your EE code and a link to your page so we can investigate?

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

ExpressionEngine News!

#eecms, #events, #releases