The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums CSS Bottom div starting underneath the top one

  • This topic is empty.
Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
  • #35468

    What I want to do is this:

    So I have the logo floated left and a div with the other 2 things floated right and text-align right. That’s all ok.

    Now I want to give the description margin-top:35px from languages. When I do it, the margin appears underneath the languages div. I can add more margin to have the element where I want but I wanted to understand why is acting like that.

    Any idea?

    EDIT: I’ve made the jsFiddle example to show what’s appearing me:


    There were a couple of issues to do with floating and the code itself, the main culprit was #languages h3 as the header isn’t a child of #languages at all. Here is a working version:


    You’re right, thank you.


    No worries!

Viewing 4 posts - 1 through 4 (of 4 total)
  • The forum ‘CSS’ is closed to new topics and replies.