Advertisement
If you have a new account but are having problems posting or verifying your account, please email us on hello@boards.ie for help. Thanks :)
Hello all! Please ensure that you are posting a new thread or question in the appropriate forum. The Feedback forum is overwhelmed with questions that are having to be moved elsewhere. If you need help to verify your account contact hello@boards.ie

css help

Options
  • 24-02-2008 3:53pm
    #1
    Registered Users Posts: 872 ✭✭✭


    Hi,

    Please see attached image, i am trying to make the quickguide div stay on the right and have the 3 hotel divs wrap themselves around it (their width is 100% so i thought they would just wrap around the quickguide div that floats right.

    Maybe it's a clear:right issue or something similar.

    Any ideas ?

    Thanks


Comments

  • Registered Users Posts: 3,594 ✭✭✭forbairt


    Hmmm I'm guessing the quick div is absolutely positioned ? or ?

    Try giving your hotel divs a margin-right: 250px .. or whatever size the quick div is plus a bit


  • Registered Users Posts: 872 ✭✭✭grahamor


    Thanks forbairt,

    I havent specified any absolute positioning.

    I could set the margin-right to 250px for the hotel div's but say the quick div is 500px in height; and there are 10 hotel divs ( about 1500px in height in total) i want the hotel divs under the quick div to expand 100% of the width available.

    I hope i am being clear

    Thanks


  • Closed Accounts Posts: 7,145 ✭✭✭DonkeyStyle \o/


    I tried doing it in just css, but gave up.
    If the quickguide div is a fixed height, what I'd do in this case is cheat a bit with php and specify the first n rows should be only x% wide until they've cleared the quickguide.

    Something like:
    <div class="hotelrow narrow">
    <div class="hotelrow narrow">
    <div class="hotelrow narrow">
    <div class="hotelrow narrow">
    <div class="hotelrow">
    <div class="hotelrow">
    <div class="hotelrow">
    <div class="hotelrow">


  • Registered Users Posts: 35,524 ✭✭✭✭Gordon


    The closest I got was by stating the hotel divs as display:table-cell; but as I don't understand what that means I couldn't work out why only the first div would fit until the left edge of the quickdiv and the rest would bunch up on the same row as the first. display:table-row; gave me some results also but removed the border style for some reason.

    Might be something to look into for someone with a greater knowledge though.


  • Closed Accounts Posts: 7,145 ✭✭✭DonkeyStyle \o/


    Gordon wrote: »
    display:table-cell; but as I don't understand what that means [...]
    I have to say this is the first I've seen of this display:table malarkey... is this part of a more recent css spec? or have I just been living under a rock :confused:

    /dons Sherlock Holmes hat and wanders off to google to investigate


  • Advertisement
Advertisement