Grow your CSS skills. Land your dream job.

Divs with hide/show function attached are hidden with recordset paging links.

  • # July 7, 2013 at 1:06 pm

    I have a set of three ‘tabs’ which are contained in an outer div. This outer tab is hidden at the bottom of the screen by default, and animates up/down on clicking the div ‘clickme’.

    Each tab is numbered 1 to 3 with 1 being the default and therefore visible. Clicking the link makes tab2 visible and hides tab1 etc.

    Each tab contains data pulled from a record set, and recordset paging links to go to the next set of data from the recordset (but still within the same tab).

    My problem is that when you click the links to the next or previous set of data (inside ) the slideout div animates back down AND resets back to the default tab (tab1). So for example, if you’re on tab3 and click the arrow for the next set of data, the div ‘slideout’ animates down, tab1 is shown and tab3 is hidden.

    I need ‘slideout’ div to remain shown and the correct tab to remain visible too.

    Attached is the HTML body (with some sections removed to condense) along with the two functions to perform the animate, and swap tabs.

    Please please help! I’m lost!




    // content here

    < ?php if ($pageNum_main > 0) { // Show if not first page ?>
    “>


    < ?php } // Show if not first page ?>
    < ?php if ($pageNum_main < $totalPages_main) { // Show if not last page ?>
    “>


    < ?php } // Show if not last page ?>


    // content & forward/back arrow would be in here as in tab1


    // content & forward/back arrow would be in here as in tab1



Viewing 1 post (of 1 total)

You must be logged in to reply to this topic.

*May or may not contain any actual "CSS" or "Tricks".