BuddyBoss Home – Web Support Forums Themes BuddyBoss theme Code to move left sidebar widgets UNDER site content

Viewing 7 posts - 1 through 7 (of 7 total)
  • Question

    #34033

    Alyssa
    Participant
    @alyssa-buddyboss

    @george123 New code to move the left sidebar on mobile, add to child theme functions.php:

    function move_left_sidebar(){
    ?>
    <script>
    if ( $("#mobile-check").is(':visible') ) {
    	$('#main .left-widget-area').insertAfter($('#main .site-content'));
    }
    </script>
    <?php
    }
    add_action( 'wp_footer' , 'move_left_sidebar' );

    Answers

    #34034
    @george123

    @tjchester is something missing? I copy/pasted that to functions.php with no change.

    Check my site for testing purposes if needed. Pasted that into functions.php.

    #34036

    Alyssa
    Participant
    @alyssa-buddyboss

    @george123 yes, I was going about it the wrong way. Inline fixed above is some new code that is 1) upgrade safe and 2) works on resize!
    Tested 110% upways, downways and slantways.

    #34041
    @george123

    It is working now, but by default it loads the other content, then when you touch the screen.. it pushes the correct content to the top. It used to put the site content automatically up top.

    #34043

    Alyssa
    Participant
    @alyssa-buddyboss

    @george123 ok, removed the resize coding portion. Thought it was working :(. Fixed now 🙂

    #34046
    @george123

    b-e-a-uuutiful

    Thanks again.

    #34049

    Alyssa
    Participant
    @alyssa-buddyboss

    No problem.

Viewing 7 posts - 1 through 7 (of 7 total)
  • The question ‘Code to move left sidebar widgets UNDER site content’ is closed to new replies.