The new forums will be named Coin Return (based on the most recent vote)! You can check on the status and timeline of the transition to the new forums here.
The Guiding Principles and New Rules document is now in effect.

HTML/PHP Excess blank space

rfaliasrfalias Registered User regular
edited December 2009 in Help / Advice Forum
So, I'm using domcollapse and I have a large dataset from mysql and it displays fine, but the main page scrollbar is ridiculously huge. I can hide it with overflow: hidden in the body but the page can't be scrolled if the resolution is too small.

http://hollowsociety.com/beerdb/arraytest.php

Reference page there.

I only want to have to scroll if the main form is out of the main page. But it seems like the dataset in the div is overflowing even though there is no data.

I can post any of the php as needed.

I'm kinda rusty on all of this and I'm sure it's not so efficient but just toying around for my own personal fun and this has been haunting me. Tried modifying the CSS and everything to no avail. While 'hidden' works, it's not really removing the blank data.

rfalias on

Posts

  • SeñorAmorSeñorAmor !!! Registered User regular
    edited December 2009
    It's definitely something with your Javascript, as disabling it causes the page to render fine (except, of course, for the uncollapsed elements).

    Might I suggest you consider using jQuery? It'd probably make what you want to do a load easier.

    SeñorAmor on
  • rfaliasrfalias Registered User regular
    edited December 2009
    Mmm thanks a bunch!!

    A once over and its already a bunch better!

    http://hollowsociety.com/beerdb/jqmenu.php

    Is there a jquery function to tell when it's toggled? It's simple im sure, but I'd something like a .toggled for when it's clicked to change the color
    *hmmmmm stumped*

    rfalias on
  • flatlinegraphicsflatlinegraphics Registered User regular
    edited December 2009
    rfalias wrote: »
    Mmm thanks a bunch!!

    A once over and its already a bunch better!

    http://hollowsociety.com/beerdb/jqmenu.php

    Is there a jquery function to tell when it's toggled? It's simple im sure, but I'd something like a .toggled for when it's clicked to change the color
    *hmmmmm stumped*

    try the toggle() function :mrgreen:
    http://docs.jquery.com/Effects/toggle

    flatlinegraphics on
  • rfaliasrfalias Registered User regular
    edited December 2009
    Toggle seemed to make all of the specified headers open at the same time. Maybe I was using it wrong, but...

    $(document).ready(function(){
    $("h2").click(function () {
    $("h2").toggle();
    $("p").toggle();
    });
    });
    If I click h2 ALL of the H2's would open. Since it's php and they are all marked h2... yeah.

    rfalias on
  • SeñorAmorSeñorAmor !!! Registered User regular
    edited December 2009
    You'd probably want something like:
    $(this).toggleClass('whatever');
    $(this).next().toggle();
    

    SeñorAmor on
  • rfaliasrfalias Registered User regular
    edited December 2009
    Well now that the forum is back... Figure I better mark this resolved!

    http://www.hollowsociety.com/beerdb/jqmenu.php

    Thanks a ton!

    rfalias on
Sign In or Register to comment.