Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 6 of 6
  1. #1
    Regular Coder noneforit's Avatar
    Join Date
    Apr 2009
    Location
    England
    Posts
    268
    Thanks
    10
    Thanked 20 Times in 20 Posts

    Question about width?

    Hello

    I asked a similar question previously but this is a different question/problem

    I have a #wrapper id which is set to width:80% meaning it stretches according to the screen resolution.

    However I then have an #inner tag which has a fixed width of 950px as i dont want the content to stretch if the screen reolution changes as the elements have a fixed widths.

    In IE the page is centred but in firefox the whole page is aligned right and will only centre if i change the width of the #inner tag to be auto;.....cant really win on this one?

    Link is:

    www.noneforit.com/marie/index.html

  • #2
    Senior Coder
    Join Date
    Feb 2009
    Location
    Ilkley, West Yorkshire, UK
    Posts
    2,957
    Thanks
    9
    Thanked 727 Times in 721 Posts
    Not sure I'm understanding the problem here.

    Your page looks exactly the same to me in IE7 and FF3, at 1280 by 1024.
    At full width #inner remains centred within #wrapper.

    Have I misunderstood?

  • #3
    Regular Coder noneforit's Avatar
    Join Date
    Apr 2009
    Location
    England
    Posts
    268
    Thanks
    10
    Thanked 20 Times in 20 Posts
    Change your resolution to 1024x768 and the problem becomes evident

    Thanks

  • #4
    Supreme Master coder! abduraooft's Avatar
    Join Date
    Mar 2007
    Location
    N/A
    Posts
    14,865
    Thanks
    160
    Thanked 2,224 Times in 2,211 Posts
    Quote Originally Posted by laurieballard View Post
    Change your resolution to 1024x768 and the problem becomes evident

    Thanks
    1024 x 80/100 = 819.2 is always less than 950 and it was already answered in your previous thread.
    Last edited by abduraooft; 06-01-2009 at 01:52 PM.
    The Dream is not what you see in sleep; Dream is the thing which doesn't let you sleep. --(Dr. APJ. Abdul Kalam)

  • #5
    Senior Coder
    Join Date
    Feb 2009
    Location
    Ilkley, West Yorkshire, UK
    Posts
    2,957
    Thanks
    9
    Thanked 727 Times in 721 Posts
    Ok, got it now, although it still looks the same in IE7 and FF3.

    Might be off target (again...) but why not remove #wrapper completely, centre #inner and apply a max-width of 950px?

  • Users who have thanked SB65 for this post:

    noneforit (06-01-2009)

  • #6
    Regular Coder noneforit's Avatar
    Join Date
    Apr 2009
    Location
    England
    Posts
    268
    Thanks
    10
    Thanked 20 Times in 20 Posts
    Thanks very much SB65 it worked great

    Wrapper tag now gone and the #inner tag is now:

    #inner
    {
    width: auto;
    height:690px;
    margin: auto;
    max-width: 950px;
    border:#000000 1px solid;
    }



  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •