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 3 of 3
  1. #1
    New to the CF scene
    Join Date
    Nov 2012
    Posts
    6
    Thanks
    2
    Thanked 0 Times in 0 Posts

    Question Beginner Mistake by CSS styling

    Hi guys,

    I am about to learn CSS. Today I made a web page which you can find here: http://acecars24.com/test

    The code might includes many mistakes, however what makes me crazy is the fact, that if I make the Browser window smaller, the sidebar (in pink) jumpt underneath the main content.

    What is my mistake?

    Thanks

  • #2
    Master Coder Excavator's Avatar
    Join Date
    Dec 2006
    Location
    Alaska
    Posts
    9,675
    Thanks
    22
    Thanked 1,827 Times in 1,811 Posts
    Hello kayut,
    When #wrapper narrows up to where your #main and aside do not fit beside each other, the elements start re-arranging themselves so they do fit. That's what they're supposed to do.

    To stop that, set either a width or a min-width on #wrapper.
    Validate often DURING development - Use it like a splelchecker | Debug during Development |Write it for FireFox, ignore IE
    Use the right DocType | Validate your markup | Validate your CSS | Why validating is good | Why tables are bad

  • #3
    New to the CF scene
    Join Date
    Nov 2012
    Posts
    6
    Thanks
    2
    Thanked 0 Times in 0 Posts
    Thanks for your reply.
    I know. Meanwhile I changed the code and it works now the way I wanted.

    The next problem is:

    What should I add to my CSS code, so that the sidebar is always as heigh as the main content??
    Last edited by kayut; 11-26-2012 at 06:27 PM.


  •  

    Posting Permissions

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