Results 1 to 9 of 9

Thread: aligning divs

  1. #1
    Join Date
    Jul 2006
    Location
    Antwerp, Belgium (Europe)
    Posts
    927
    Thanks
    121
    Thanked 2 Times in 2 Posts

    Default aligning divs

    Hey guys,
    I have a site devided in divs. THis is how it looks like, where + is an iframe, and = a div (http://www.hetbestevoordeel.be)
    ==++
    ==++
    ====
    ====
    When I want to place a div next to the iframe, it looks like this, leaving the space next to the iframe empty(0).
    ==++00
    ==++00
    ======
    ======
    But this what I need, where the divs go around the iframe.
    ==++==
    ==++==
    ======
    ======
    Hopefully this is clearly explained, and can someone help me how to get the alignement correctly. Thanks !
    You can find the stylesheets here: http://www.hetbestevoordeel.be/style/stylesheet.css

  2. #2
    Join Date
    Jul 2006
    Location
    Antwerp, Belgium (Europe)
    Posts
    927
    Thanks
    121
    Thanked 2 Times in 2 Posts

  3. #3
    Join Date
    Mar 2007
    Location
    Tarboro, NC
    Posts
    290
    Thanks
    8
    Thanked 2 Times in 2 Posts

    Default

    Does iframe have the float property in CSS? I don't use iframes, but have you tried using float left then using one big DIV to contain them all? If thats what your doing, then I'm clueless. Just trying to give a little help if I can.

  4. #4
    Join Date
    Jul 2006
    Location
    Antwerp, Belgium (Europe)
    Posts
    927
    Thanks
    121
    Thanked 2 Times in 2 Posts

  5. #5
    Join Date
    Jul 2006
    Location
    just north of Boston, MA
    Posts
    1,806
    Thanks
    13
    Thanked 72 Times in 72 Posts

    Default

    having the iframe in the middle of 2 lines of text could get very very confusing unless it will never have the possibility of containing anything but a none textual media type, image / movie clip, and thus should be avoided at all costs, as it breaks convention.

  6. #6
    Join Date
    Sep 2007
    Posts
    2
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    I would try adding display inline to
    see what happens before trying float.

    Besides iframes, you might try using
    object tags instead.
    http://www.w3schools.com/media/media_object.asp

    sm

  7. #7
    Join Date
    Jul 2006
    Location
    Antwerp, Belgium (Europe)
    Posts
    927
    Thanks
    121
    Thanked 2 Times in 2 Posts

    Default

    What's the difference between the object tags and iframes ?
    I now use iframes because the content around it takes a while to load.
    I would try adding display inline to
    see what happens before trying float
    like this ?
    Code:
    inline: top;

  8. #8
    Join Date
    Jul 2006
    Location
    just north of Boston, MA
    Posts
    1,806
    Thanks
    13
    Thanked 72 Times in 72 Posts

    Default

    display: inline and
    vertical-align: top

    two different tags. The first will create a horizontal list, while the latter will just attempt to move all of the text to the very top of the element, rather then centering it vertically.

  9. #9
    Join Date
    Mar 2007
    Location
    Tarboro, NC
    Posts
    290
    Thanks
    8
    Thanked 2 Times in 2 Posts

    Default

    Just to clarify what I mean.
    I---------I
    I ==++== I
    I ==++== I
    I ====== I
    I ====== I
    I---------I

    The outline is the DIV, then give it a maximum forced height and width, so that it might force it to align. Idk.

Bookmarks

Posting Permissions

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