Solved

CSS Help with IE6 block display problem

Posted on 2007-03-26
6
325 Views
Last Modified: 2013-11-19
CSS block problem in Joomla template. My div column block keeps going underneath my main content in IE6. It displays fine in FF and IE7.

Basically I want to include a flash menu to the left and content to the right.I can't get my text to wrap around a div block. Look at: http://www.bestcompanies.ie/index.php?option=com_content&task=view&id=114&Itemid=80 in IE6 for example.

The section in my template shows:

 <div id="wrapper">
            <div id="content"><?php mosMainBody(); ?></div>
 </div>
       
 <div id="navigation">
      <img src="http://www.bestcompanies.ie/templates/gptw-flash/images/betsy.gif" width="220" height="228" align="left" />
</div>

My CSS code includes:
div#wrapper{
      float:right;
      width:100%;
      height:auto;
      margin-left:-200px;
}

div#content{
      margin-left:200px;
      padding:0px 15px 0px 15px;
      text-align:justify;
      float:left;
}

div#content p{
      line-height:1.4;
}

div#navigation{
      float:left;
      width:200px;
      vertical-align:top;
}


Many thanks in advance
0
Comment
Question by:otooles
6 Comments
 
LVL 18

Accepted Solution

by:
Eternal_Student earned 250 total points
ID: 18793210
Its possibly a width issue. Check all of your width settings + padding + margin and make sure it all adds up in IE. Remember IE handles the box model differently than Mozilla.

This could also be the IE float bug. That is where IE doubles the margin on any element that is floated. So if you float something and give it a margin 8px IE will render that as margin 16px. Double margin bug can be fixed by adding this to the element that is floated:

display:inline;
0
 

Author Comment

by:otooles
ID: 18793407
If I decrease the width of my menu it fits in. However I want my column menu to flyout over the conent on mouse over so my flash file needs to be wider.

So my menu will overlap as below. Small menu box to the left with larger content box to the right.

--------------------
|----/---|----------/  |
|     /    |              /  |
|     /    |              /  |
|----/---|             /  |
|     /--------------/  |
-----------------------
     
--------------------
0
 
LVL 3

Assisted Solution

by:dtocci
dtocci earned 250 total points
ID: 18805736
By the looks of your layout, you could use absolute positioning on your menu and content divs to solve your cross-browser problems.  They appear to always be the same distance from the top of the page.  If this were my layout, and I understand you correctly, I would actually place both at 0 on the left, but with the menu on top of the content. You can then set the left padding on the content to make room for the menu.  You can even set the content div to contain the background image, which would help fix the issue with the content spilling over the bottom as it does currently.  The menu would also be positioned at 0 left, but with no left margin and a higher z-index.  Of course, this would not allow content to *wrap* under the menu, but it doesn't appear to do that now anyway even in firefox.
0

Featured Post

Master Your Team's Linux and Cloud Stack!

The average business loses $13.5M per year to ineffective training (per 1,000 employees). Keep ahead of the competition and combine in-person quality with online cost and flexibility by training with Linux Academy.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Boost your ability to deliver ambitious and competitive web apps by choosing the right JavaScript framework to best suit your project’s needs.
Color can increase conversions, create feelings of warmth or even incite people to get behind a cause. If you want your website to really impact site visitors, then it is vital to consider the impact color has on them.
In this tutorial viewers will learn how to style rounded corners for elements in CSS using the border-radius property Begin with a normal styled element such as a div: To style all four corners of the div to be the same degree of roundness, use the …
The is a quite short video tutorial. In this video, I'm going to show you how to create self-host WordPress blog with free hosting service.

778 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question