0
Welcome Guest! Login
0 items Join Now

IE Specific Stylsheet

  • IE Specific Stylsheet

    Posted 13 years 11 months ago
    • I need to add an IE9 specific style sheet to my template (mynxx J1.5 if that matters). I've added the file to the theme css folder. Looking at the index file I saw that the css file links are called by the <jdoc:include type="head" /> command. Having found the head file (librarys/joomla/document/html/renderer/head.php) I can see where the links are being generated. This implies to me (tell me if I'm wrong! I haven't dealt with this before) that the links are generated on the fly from the css folder - even the IE specific style sheets, of which there are already IE6 and IE7 which come with the template - so if I simply add the stylesheet for IE9 to the css folder then a link should be correctly generated for it in the head of the index file.

      But it's not! - so far as I can tell, by looking at what styles are being called in IE9.

      Where have I gone wrong? What can I do to call an IE9 specific style sheet in the index head?

      Thanks!
    • Ben Lee's Avatar
    • Ben Lee
    • Elite Rocketeer
    • Posts: 4193
    • Thanks: 42

    Re: IE Specific Stylsheet

    Posted 13 years 11 months ago
    • This only works for IE browser versions, but it was added by them because they regularly need some help on things that show up fine in other browsers.

      Create your template-ie9.css stylesheet and put it in the same css folder. Then you'll need to add it to the head of your site using this code so it's only called in when IE9 is being used...
      <!--[if IE 9]>
      <link href="/templates/rt_mynxx_j15/css/template_ie9.css" rel="stylesheet" type="text/css" />
      <![endif]-->

      I haven't tested this yet with IE9, but this is the procedure for adding stylesheets to all other previous IE versions.
  • Re: IE Specific Stylsheet

    Posted 13 years 11 months ago
    • Ah, this worked. Thank you! :cheesy:

Time to create page: 0.055 seconds