Hello. Thank you for this great framework theme. I am working on a site and have been testing it with IE7 and FF3. Everything appears great in FF3, but in IE7 my background image in the primary links does not show up. I posted a question about this on the general forums of drupal.org, but figured I would post here since the following solution didn't work. First we have my code from style.css, then we have a space, and then we have the suggestion for the new code for style.css to replace mine. Unfortunately, this recommendation did not work. I also tried making the image file smaller size just in case it was too big for IE (75px by 25px, tried also 60px by 20px), and i also tried using a png, a gif, or a jpg - neither will work in IE7 but all work in FF3. Don't you just wish everyone used FF? :P

#nav ul.primary-links {
padding-left: 90px; /* wasnt here before */
padding-top: 5px; /* wasnt here before */
padding-bottom: 5px; /* wasnt here before */
background-position: center left; /* wasnt here before */
background:url(icons/artists-menu.png) no-repeat; /* background: #ffffff; */ /* was #d4e7f3 */
float: center;
font-weight: 700;
/* padding: 5px; */
}

to

#nav ul.primary-links {
padding-left: 90px; /* wasnt here before */
padding-top: 5px; /* wasnt here before */
padding-bottom: 5px; /* wasnt here before */
background-position: center left; /* wasnt here before */
background:url(icons/artists-menu.png) no-repeat; /* background: #ffffff; */ /* was #d4e7f3 */
float: center;
font-weight: 700;
min-height: 25px; /* wasnt here before */
/* padding: 5px; */
}

Comments

andregriffin’s picture

It seems maybe a float is not cleared somewhere. Try this: open up page.tpl.php and find the "nav" div.

Add a <span class="clear"></span> right before nav div closes, like so:

      <div id="nav">
        <?php if (isset($primary_links)) : ?>
          <?php print theme('links', $primary_links, array('class' => 'links primary-links')) ?>
        <?php endif; ?>
        <?php if (isset($secondary_links)) : ?>
          <?php print theme('links', $secondary_links, array('class' => 'links secondary-links')) ?>
        <?php endif; ?>
        <span class="clear"></span>
      </div> <!-- /#nav -->

If that doesn't work, you may need to isolate your primary links with another div, like so:

      <div id="nav">
        <?php if (isset($primary_links)) : ?>
          <div id="primary-links">
            <?php print theme('links', $primary_links, array('class' => 'links primary-links')) ?>
            <span class="clear"></span>
          </div>
        <?php endif; ?>
        <?php if (isset($secondary_links)) : ?>
          <?php print theme('links', $secondary_links, array('class' => 'links secondary-links')) ?>
        <?php endif; ?>
        <span class="clear"></span>
      </div> <!-- /#nav -->

Then in your css, target your background to #nav div#primary links instead.

wrb123’s picture

andregriffin, IT WORKED! your first method worked great. thank you so much! IE is a pain, but this theme is great - i really appreciate your work on it.
thanks,
bill

andregriffin’s picture

Status: Active » Fixed

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for two weeks with no activity.