Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

css compatibility width IE7

Hi I'm having some problem with css to IE7

I want to put some text side-by-side width an image. like this: http://imageshack.us/photo/my-images/14/imgwx.png/

The problem is that in IE7 the text appears below the image.

I have the following HTML code:

   <div id="imageArticle"><img="src/here.jpg"></div>
   <div id="contentArticle">TEXT HERE </div>

  #imageArticle {
        float: right;
        margin-bottom: 20px;
        margin-left: 20px;
        margin-top: 15px;
        position: relative;
    }
#contentArticle {
    color: #333333;
    font-size: 13px;
    line-height: 17px;
    margin-top: 90px;
    padding-bottom: 20px;
    position: relative;
    width: 750px;
}

Any suggesstions?? Thanks

like image 920
saomi Avatar asked Sep 25 '26 22:09

saomi


2 Answers

Insert your image inside #contentArticle and then float it to right

like image 120
Malyo Avatar answered Sep 28 '26 02:09

Malyo


As I undrestood right you should do like this:

<html>
    <body>
    <div style="width:200px">
        <img class="myimage" src="test.jpg" width="90" height="90" style="float:right;"/>
        blabla bla blalbalba
        blabla bla blalbalba
        blabla bla blalbalba
        blabla bla blalbalba
        blabla bla blalbalba
        blabla bla blalbalba
        blabla bla blalbalba
    </div>
    </body>
</html>

Text and Image side by side

I've tested it on IE7 and it works fine.

like image 31
Eugene Trofimenko Avatar answered Sep 28 '26 03:09

Eugene Trofimenko



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!