Viewing 8 posts - 1 through 8 (of 8 total)
  • Author
    Posts
  • #1265445

    Hey guys,

    A client we built a site for years ago has ran into some issues recently, and asked me to look into it. One of the issues is not being able to use the Avia layout builder after updating wordpress to 5.1.8.

    I decided that upgrading the skin would be the best bet, however, there are some issues with a misaligned navigation bar at the top, and the collapsing sticky header no longer works correctly.

    If we could some feedback on this that would be great! Many thanks!

    #1265492

    Hi,

    Thanks for contacting us!

    I believe both issues could be fixed with CSS however to make sure, we would need to see the issues. Would it be possible for you to create a testing environment and update the theme there so we can inspect the issues and compare it to live one? :)

    Cheers!
    Yigit

    #1265786

    Hi Yigit,
    Thanks for the reply. Do you guys know if a more streamlined way than backing up the entire site, downloading and then uploading to a different server and going through the wordpress setup again?

    I have been out of the loop for quite a while, there must be an easier way to move a wordpress site.

    #1265809

    Hi RitchieTheBrit,

    Here is an article for you:

    If you need further assistance please let us know.
    Best regards,
    Victoria

    #1285487

    Hi guys, sorry for the long wait for a reply. The client has been back on to me, and I have been playing around rebuilding the child theme on my localhost.
    Unfortunately due to terrible compatability from Namesco, I cannot load it onto a demo server.
    Everything is working bar the header. It turns out I had modified the AVIA.JS file for the child theme, but I’m NOT a coder, and I’m struggling to see how I can implement this in the current version. Please see below for the code I used in the child…

    /* Navigation mods to lower links in header. Follwing function needs to replace existing function in AVIA.JS */
    function avia_header_size()
        {
            var win	            = $(window),
                header          = $('.fixed_header #header'),
                //logo			= header.find('.logo img'),
                logo            = $('#header_main .container .logo img, #header_main .container .logo a'),
                elements        = $('#header_main .container, .main_menu ul:first-child > li > a:not(.avia_mega_div a)'),
                el_height       = $(elements).filter(':first').height(),
    		// START Reposition Menu - find height of .main_menu
    			top_height		= $('.main_menu').height(),
    		// END Reposition Menu
                isMobile        = 'ontouchstart' in document.documentElement,
                scroll_top		= $('#scroll-top-link'),
                set_height      = function()
                {
    		// START Reposition Menu - include new variable topH
                    var st = win.scrollTop(), newH = 0, topH = 0;
    		// END Reposition Menu
                    if(st < el_height/2)
                    {
                        newH = el_height - st;
    		// START Reposition Menu - Set topH at max
    					topH = 175 - st;
    		// END Reposition Menu
                        header.removeClass('header-scrolled');
                    }
                    else
                    {
                        newH = el_height/2;
    		// START Reposition Menu - Set topH at min
    					topH = 75;
    		// END Reposition Menu
                        header.addClass('header-scrolled');
                    }
    
                    elements.css({'height': newH + 'px', 'lineHeight': newH + 'px'});
                    logo.css({'maxHeight': newH + 'px'});
    		// START Reposition Menu - Assign topH to the CSS class
    				$('.main_menu').css({top: topH + 'px'});
    		// END Reposition Menu
                }
    
            	if(!header.length) return false;
    
                if(isMobile)
                {
                    return false;
                }
    
                win.scroll(set_height);
                set_height();
        }

    How could this be achieved in the current skin? Many thanks!

    #1286468

    Hi,

    Thanks for contacting us!

    avia_header_size function is now inside enfold/js/avia-snippet-sticky-header.js file. Please have a back up and then replace the function with your version.

    Best regards,
    Yigit

    #1286482

    Hi Yigit,
    I found the file and tried that, as well as transplanting my additional code into the newer script (I think some of the class references have changed).
    It seems that $(‘.main_menu’).css({top: topH + ‘px’}) is never applied to the navigationc container class main_menu. I can see the dynamic sizing applied to the header div, but not on the main_menu class.

    Is there anything glaring in the code that would cause this? I adapted this script YEARS ago now.

    Many thanks!

    #1287902

    Hi,

    Sorry for the late reply. I see that you are currently running 4.7.6.4 on the site, and the header seems to be working fine on my end. I might be missing the point as to what you are trying to achieve or fix here, could you try to explain the problem a bit further please?

    Best regards,
    Rikard

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