1. HOT Divi Ultimate Header Plugin - More variety for your Divi header: https://header.diviultimate.com/
This is the support forum for Divi Powerful Child Theme.

To access this support forum, you need to purchase Divi Powerful Child Theme.

If already purchased, kindly login to your account to access it.
For Divi community forum, kindly visit here: https://divi.help/forums/get-help-on-divi-wordpress.30/

Solved Problem with anchor links on WP 5.6

Discussion in 'Basic Support Forum' started by Appnweb, Dec 10, 2020.

  1. Appnweb

    Appnweb New Member
    Divi Powerful Child Theme Divi Ultimate Archive Plugin Divi Ultimate Blog Plugin Divi Ultimate Header Plugin Divi Ultimate Footer Plugin

    Hello,

    Just updated one of our website to WP 5.6, Divi 4.7.5 and DU powerful child theme 1.1.2 and I encounter the same problem I had on another website with Divi 4.7.4, the menu anchor links do not work.

    As version 4.7.5 of Divi did fix the issue on the other website on which we do not have DU powerful child theme, I guess the cause is probably the same.

    I installed the Jquery Migrate Helper plugin to temporarily fix the issue and it's working correctly this way but it would be great if it could be fixed in next version

    Thanks in advance for your help and have a nice day.
     
    1. AD Easily add Mega Menu for your Divi site: https://divi.help/link-forums/divi-mega-pro.149/
  2. Divi Powerful

    Divi Powerful Administrator
    Staff Member

    The anchor link code fix is located at the child theme folder.

    If you have not made any changes to the child theme files (style.css / functions.php / etc), then you may switch it back to the parent Divi theme & delete the child theme & upload the new one (Divi-Powerful.zip): https://divi.help/threads/divi-powerful-child-theme-v1-1-2.7138/

    If you did make changes to the child theme files, then you shouln't be deleting the child theme. And here's the one file that you need to edit:
    - Go to WP Admin > Appearance > Theme Editor > Divi Powerful Child Theme > dp-assets > js > main.js & replace with the below:
    Code:
    !function(e){e(document).ready(function(){function t(){e(".free-search-container").hasClass("et_pb_is_animating")||(e(".et_pb_fullwidth_menu, .et_pb_menu").removeClass("free-menu-hidden et_pb_no_animation").addClass("free-menu-visible"),e(".free-search-container").removeClass("free-search-visible et_pb_no_animation").addClass("free-search-hidden et_pb_is_animating"),setTimeout(function(){e(".et_pb_fullwidth_menu, .et_pb_menu").addClass("et_pb_no_animation"),e(".free-search-container").addClass("et_pb_no_animation").removeClass("et_pb_is_animating")},450))}e(".free-search-icon-link").click(function(t){t.preventDefault();var i=e(".free-search-container");i.hasClass("et_pb_is_animating")||(e(".et_pb_fullwidth_menu, .et_pb_menu").removeClass("free-menu-visible et_pb_no_animation").addClass("free-menu-hidden"),i.removeClass("free-search-hidden et_pb_no_animation").addClass("free-search-visible et_pb_is_animating"),setTimeout(function(){e(".et_pb_fullwidth_menu, .et_pb_menu").addClass("et_pb_no_animation"),i.addClass("et_pb_no_animation").removeClass("et_pb_is_animating")},450),i.find("input").focus())}),e(".free-search-close").click(function(){t()}),e(document).mouseup(function(i){var n=e(".et_pb_fullwidth_menu, .et_pb_menu");e(".et_pb_fullwidth_menu, .et_pb_menu").hasClass("free-menu-hidden")&&(n.is(i.target)||0!==n.has(i.target).length||t())})}),window.et_pb_smooth_scroll=function(t,i,n,a){var r=e(window).width();e("body").hasClass("et_fixed_nav")&&r>980?$menu_offset=(e("#top-header").outerHeight()||0)+(e("#main-header").outerHeight()||0)-1+(e(".free-sticky-wrapper:eq(0)").outerHeight()||0)+(e(".free-sticky-wrapper:eq(1)").outerHeight()||0)+(e(".free-sticky-wrapper:eq(2)").outerHeight()||0)+(e(".free-sticky-wrapper:eq(3)").outerHeight()||0)+(e(".free-sticky-wrapper:eq(4)").outerHeight()||0):$menu_offset=(e(".free-sticky-wrapper:eq(0)").outerHeight()||0)+(e(".free-sticky-wrapper:eq(1)").outerHeight()||0)+(e(".free-sticky-wrapper:eq(2)").outerHeight()||0)+(e(".free-sticky-wrapper:eq(3)").outerHeight()||0)+(e(".free-sticky-wrapper:eq(4)").outerHeight()||0)-1,e("#wpadminbar").length&&($menu_offset+=e("#wpadminbar").outerHeight()||0),$scroll_position=i?0:t.offset().top-$menu_offset,void 0===a&&(a="swing"),e("html, body").animate({scrollTop:$scroll_position},n,a)}}(jQuery);
    Let me know how it goes.
     
  3. Appnweb

    Appnweb New Member
    Divi Powerful Child Theme Divi Ultimate Archive Plugin Divi Ultimate Blog Plugin Divi Ultimate Header Plugin Divi Ultimate Footer Plugin

    Working perfectly, thanks a lot. Maybe, it could help to mention it in the upgrade instruction.

    Have a nice day.
     
    Divi Powerful likes this.
    1. AD Power up your Divi sites with tons of new functionalities: https://divipowerful.divi.help/