Solved

HTML5/CSS floats display incorrectly with IE7

Posted on 2012-04-12
4
461 Views
Last Modified: 2012-06-27
I'm building a small website for a business. I'm not that well trained in coding. I use the web to troubleshoot often. I have found one error of display only in IE7 that is driving me nutz...lol !!! I'm utilizing HTML5 for rounded corners and shading...

I'm using a "container" div with 3 columns...I float left on the first...float right on the second...and then content for the center...displays just fine in all browsers aside from IE7...the "content" drops halfway down the page? I've used the "clear" function and "display" to no success?

Any ideas for this problem would be greatly appreciated !!!

#container2 {
      overflow: hidden;
      background-color:#fff;
      margin-left:auto;
      margin-right:auto;
      height:auto;
      width:960px;
      clear:all;
}

#leftside {
      float:left;
      margin:10px 10px 10px 10px;
      width:145px;
            border-style:solid;
      border-width:1px;
      border-color:#d7d7ff;
      -moz-border-radius: 15px;
      -webkit-border-radius: 15px;
   -khtml-border-radius: 15px;
    border-radius: 15px;
}

#rightside {
      float:right;
      margin:10px 10px 10px 10px;
      width:145px;
                  border-style:solid;
      border-width:1px;
      border-color:#d7d7ff;
      -moz-border-radius: 15px;
      -webkit-border-radius: 15px;
   -khtml-border-radius: 15px;
    border-radius: 15px;
}

#content {
      overflow:hidden;
      width:620px;
      margin:10px 170px 10px 170px;
      border-style:solid;
      border-width:1px;
      -moz-border-radius: 15px;
      -webkit-border-radius: 15px;
   -khtml-border-radius: 15px;
    border-radius: 15px;
      border-color:#d7d7ff;

}
0
Comment
Question by:PCWoes
  • 3
4 Comments
 
LVL 53

Accepted Solution

by:
COBOLdinosaur earned 500 total points
ID: 37838841
IE7 does not calculate dimensions to standard.  It is most likely that the total width of the columns as calculated by IE7 is greater than the width of the container so it drops down to the next available empty area.

Either increase the width of the container until it lines up correctly, or reduce the width of one or more of the contained elements.


Cd&
0
 
LVL 53

Expert Comment

by:COBOLdinosaur
ID: 37838873
If that does not solve it I think I will need a link to the page to see what it is doing.

Cd&
0
 

Author Closing Comment

by:PCWoes
ID: 37839025
Dropped width of content 10px and solved...thank you...cross browser design is interesting for sure !!!
0
 
LVL 53

Expert Comment

by:COBOLdinosaur
ID: 37839098
It is much less of a challenge today than it was before there were any real standards. Fortunately the browser manufacturers have finally realized that competing on the basis of standards compliance is a good thing.

Cd&
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

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

Suggested Solutions

Styling your websites can become very complex. Here I'll show how SASS can help you better organize, maintain and reuse your CSS code.
Is your Office 365 signature not working the way you want it to? Are signature updates taking up too much of your time? Let's run through the most common problems that an IT administrator can encounter when dealing with Office 365 email signatures.
The viewer will learn how to create and use a small PHP class to apply a watermark to an image. This video shows the viewer the setup for the PHP watermark as well as important coding language. Continue to Part 2 to learn the core code used in creat…
The viewer will the learn the benefit of plain text editors and code an HTML5 based template for use in further tutorials.

863 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

Need Help in Real-Time?

Connect with top rated Experts

24 Experts available now in Live!

Get 1:1 Help Now