Results 1 to 3 of 3

Thread: DD Drop Down Panel + Absolute Positioning

  1. #1
    Join Date
    Dec 2008
    Posts
    10
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default DD Drop Down Panel + Absolute Positioning

    1) Script Title:
    DD Drop Down Panel

    2) Script URL (on DD):
    http://www.dynamicdrive.com/dynamici...pdownpanel.htm

    3) Describe problem:
    my pages use pure css and absolute positioning, but it seems the drop down doesnt like this setup. the only way i can get this to work is by assigning an absolute position (top:0 to the ddpanel div. this makes the panel appear on top of the header like it's suppose to, but when the panel is opened it overlaps the page rather than pushing it down. If I don't add the absolute positioning, then it will only push down the header, making the header overlap the rest of the page (which has a different absolute position). I dont mind the overlapping so much, but it would be really cool if the page could get pushed down like its suppose to. Is there any work around for this to be compatible with my setup and push down all elements even if they're absolutely positioned? many thanks

  2. #2
    Join Date
    Aug 2004
    Posts
    10,143
    Thanks
    3
    Thanked 1,008 Times in 993 Posts
    Blog Entries
    16

    Default

    Hmm I'm not sure you'll find the solution to this by changing the script. It has to come with certain modifications to your layout. There is no particular rules saying you can't put DD Drop Down Panel inside an absolutely positioned DIV, ie:

    Code:
    <div style="position:absolute; background: yellow">
    
    //DD Panel entire HTML here
    
    </div>
    However, once you do that, expanding the panel no longer affects the height of the parent container (since it's absolutely positioned), and hence won't push down any content that follows this parent DIV. I'm sure there's a workaround, but as mentioned, I think it lies in tweaking your layout somehow.
    DD Admin

  3. #3
    Join Date
    Dec 2008
    Posts
    10
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    yeah thats the problem i'm having. i have my content area and header area both positioned absolutely, and i need to keep it this way, but in order to have the drop down panel even visible above the header, it also needs to be absolutely positioned, but then it doesnt push down the page, it just overlaps everything. so i added a z-index of 999 to the ddpanel divs so it'll correctly overlap embeds too. so doesnt look like much can be done to make the ddpanel push the entire without removing the absolute positioning, but i'm okay with the overlapping, i'll just leave it like this. its a great script! I actually made the ddpanel's background a semi-transparent png which gives it a cool effect when overlapping everything else

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
  •