Make Header Stick to Top of Page with Menu

Home Forums WordPress Themes – Premium Pure & Simple Make Header Stick to Top of Page with Menu

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #17147

    Hi! I am using the Pure & Simple theme & have enabled the sticky menu. I am wondering if there is a way to make the logo stay at the top of the page with the menu as well? So when someone scrolls down the page, the logo and the menu stay at the top. Thank you!

    http://test.studio25decor.com

    #22610
    Sushil Adhikari
    Moderator

    Hi there,

    Yes of course that is possible but you need to be technically sound on wordpress [Knowledge on jquery and php].
    Here we are providing you the guideline that may help you.

    Wrap the logo section and menu section with same div tag with provide certain id or class. After this you need to customize puresimple_customizer_js.php [Go to theme folder ->inc->uresimple_customizer_js.php]. There you will find this following code:

    if (active == 1) {
    				$(window).scroll(function() {
    				if ($(window).scrollTop() > scroll_number) {
                		navigation_scrolling();
          			}
    				else {
                		$(".navigation").css({"position":"relative"});
    		 		}
       			});
    	
    			function navigation_scrolling () {
                	 $(".navigation ").css({"position":"fixed", "right":"0px", "left":"0px", "top": "0px","z-index":"9999"});
    			}

    And provide the id or class of newly created div on the above selector function. This may looks like

    if (active == 1) {
    				$(window).scroll(function() {
    				if ($(window).scrollTop() > scroll_number) {
                		navigation_scrolling();
          			}
    				else {
                		$(".class or #id of newly created div tag").css({"position":"relative"});
    		 		}
       			});
    	
    			function navigation_scrolling () {
                	 $(".class or #id of newly created div tag").css({"position":"fixed", "right":"0px", "left":"0px", "top": "0px","z-index":"9999"});
    			}

    Note: If you are not technically sound on wordpress please take a help from a developer.
    Be sure you are doing customization on child theme .So your changes will not lost on theme update.

    Thanks

    #22614

    This worked! Thank you so much for your help and quick response 🙂

    #17148
    Sushil Adhikari
    Moderator

    Hi StuFdio 25 Decor,

    That’s great, happy for you.

    Thanks

Viewing 4 posts - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.