New Landing How can we help? Cardinal Menu seperate in child theme

Viewing 7 posts - 1 through 7 (of 7 total)
  • Posted in: Cardinal
  • #233853
    djigoboom
    Member
    Post count: 30

    Hello,

    As required, I had done some changes in core files, but now I am going to split changes in child theme.
    I am facing menu issue, I have to put this code into child theme.

    if (is_page(‘distributors’) || is_page(‘distributor-registration’) || is_page(‘distributor-login’) || is_page(‘retrieve-document’) ){
    $main_menu_args = array(
    ‘echo’ => false,
    ‘theme_location’ => ‘main_navigation’,
    ‘walker’ => new sf_mega_menu_walker,
    ‘fallback_cb’ => ”,
    ‘menu’ => ‘distributors’
    );
    wp_nav_menu( $main_menu_args );
    }

    Thanks,

    #233911
    David Martin – Support
    Moderator
    Post count: 20834

    Please be specific, what is the issue relating to this:

    “I am facing menu issue, I have to put this code into child theme.”

    Thanks.

    #233957
    djigoboom
    Member
    Post count: 30
    This reply has been marked as private.
    #233967
    David Martin – Support
    Moderator
    Post count: 20834

    Ok, you need to move the actual PHP function that the code is within. Copy the function into the child theme functions.php file.

    Thanks.

    #233974
    djigoboom
    Member
    Post count: 30
    This reply has been marked as private.
    #233977
    djigoboom
    Member
    Post count: 30
    This reply has been marked as private.
    #233994
    David Martin – Support
    Moderator
    Post count: 20834

    Hi,

    That looks to be the correct function you have added. Don’t overwrite what is already in the functions.php file.

    Thanks,
    David.

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

You must be logged in and have valid license to reply to this topic.

License required for one of the following items
Login and Registration Log in · Register