Jump to content

Firefox and IE


Joshua4550

Recommended Posts

Hey, something isn't right with my styles. They work perfect with Firefox, as I want them to, but when It comes to IE - they mess up sometimes.

 

I think this is the part in question.

width:765px;
text-align:left;
position:relative;
margin:10px auto;

 

Is there something here that would be effective on Firefox and not on IE?

Link to comment
Share on other sites

The secret is to use two divs:

 

<div id="outside">
  <div id="inside">
    some stuff
  </div>
</div>

 

Then set the width on the outside div, and the margin on the inside div:

#outside
{
  width:765px;
}

#inside
{
  margin:10px;
}

Link to comment
Share on other sites

I have a div for body, then 2 divs inside it for left and right.

Sometimes in IE, they align too much to the left, if the content is too much. I just needed it to be a set padding on the left so it wouldn't do it, but it's confusing when IE is SO much different to Firefox

Link to comment
Share on other sites

Oh, and also sometimes on IE it shows the content in the right DIV, still on the right hand side, but underneath the left div though?!

 

Firefox and Chrome are fine, shows it perfect - why does IE do this?

God damn I hate microsoft with a passion :L

Link to comment
Share on other sites

No, I have an outer div and two inner divs. The problem i'm facing is that if theres too much content on the right hand side, it aligns perfectly in the middle, as it should - but then it's more to the left (for my background). I just want the extra content to be shoved to the right, not everything aligned for it.

Link to comment
Share on other sites

It's not going to work as is - you'll have to adjust your code to get it back to where it is. I gave you the proper method, you have to adjust your code to work with that method.

 

And if you want help, you need to post a code/image/a link. We aren't telepathic here unfortunately, though sometimes we try :D

Link to comment
Share on other sites

I have a width set, and it works - but IE uses that as a minimum width? How can I make IE use the width as firefox does, and if the content goes over the width, it will just display it on the right of the div?

 

I've heard of

width:700px;
max-width:700px;

But this has no effect.

Link to comment
Share on other sites

textarea {
margin: 4px;
background-color: #D2BB86;
border-color: #382418;
text-align: left;
border-style: solid;
}

 

Is there something wrong? When I use a textarea in my right hand division, it makes the division start underneath the left division, but still on the right hand side.

like so:

L
L
L
L
    R
    R
    R
    R

This is REALLY annoying, but it only happens in IE. Can someone explain to me my problem? If theres no problem with that code I can show you my other codes.

 

Thanks a bunch peeps. I'm a CSS NEWB ;D

Link to comment
Share on other sites

<div id="body">
      <div>
        <div style="text-align: center; margin-bottom: 10px; position:relative;">
          <img src="**" style="text-align:center;"><br />
        </div>
      </div>
      <div class="left">
        Hi
     </div>
     <div class="newscontainer">
       <div class="buttons">
         <textarea>HI</textarea>
       </div>
     </div>
  </div>

#body {
width:765px;
text-align:left;
position:relative;
margin:10px auto;
}
.left {
float:left;
}
.newscontainer {
margin-left:290px;
margin-bottom:40px;
}
.buttons {
width:457px;
/*height:110px;*/
position:relative;
margin:0;
}

 

Works fine in Firefox & chrome, but not IE?

(Ps: Latest Ie, I think.)

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.