Last updated 26 August 2009. Created on 31 May 2009.
Edited by chicagomom, Jeff Burnz. Log in to edit this page.

Genesis does not include any conditional comments in page templates by default. Instead I highly recommend the Conditional Styles module, which comes built into the latest version of Genesis (6.x-2.2).

The Conditional Styles module allows you to add stylesheets for Internet Explorer in your subthemes info file.

How to enable Conditional Styles

  1. Uncomment the relevant line of code in your subthemes info file (see below)

Here is the relevant code from the default genesis_SUBTHEME. Here I have included one CC stylesheet to target IE7 or less. To use just uncomment conditional-stylesheets[if lt IE 7][all][] = css/ie/ie-example.css and then start modifying the relevant stylesheet. You probably want to rename it form ie-example.css as this is of course, just for example.

;----------// IE Conditional Stylesheets

  ; Support for the Conditional Styles module. This module allows themes 
  ; to specify conditional stylesheets in their .info file and the conditional 
  ; comments will be automatically included at the end of the standard $styles variable. 
  ; Install the module and then uncomment or add the required stylesheets.
  ; There is an example IE stylesheet are in your subthemes css/ie folder.

  ; Example only: see the README in the Conditional Styles module
  ;conditional-stylesheets[if lt IE 7][all][] = css/ie/ie-example.css

If you are using an older version of Genesis (6.x-2.1 or earlier) you will need to download the Conditional Styles module and install it as a stand alone module.

Looking for support? Visit the forums, or join #drupal-support in IRC.