Viewing 11 posts - 1 through 11 (of 11 total)
  • Author
    Posts
  • #735048

    Hi

    I’m using UberMega Menu plugin on my website, but would like to use and move the Enfold search icon to my secondary menu at the top right hand of my site. I found the following ticket reference #163772 (2013) that contains a code snipet to do this. However, I don’t want updates to the theme files to overwrite this. Where and how can I add it to my functions.php of my Child theme?

    Any help would be appreciated.

    My website is currently in development and you will need login credentials to view it. I have included these int he private area.

    Thanks
    Lyse

    #736420

    Hey tremblayly,

    To add the search bar to topbar menu please add the following code to functions.php file from Appearance > Editor

    add_shortcode('avia_search', 'get_search_form');

    Add the following shortcode as menu item or in Header > Extra Elements > Header Phone Number/Extra Info

    [avia_search]


    Best regards,
    Vinay

    • This reply was modified 7 years, 3 months ago by Vinay.
    #736550

    Hi Vinay,

    I followed the instructions to add the avia_search to my topbar menu, but all I see is the “shortcode” text. It though that the following UBER Mega Menu function to remove the avia search is what’s causing it, but I removed it and still all I see is the shortcode text.

    /*UBER MEGA MENU: Remove the Enfold Search in functions.php
    Since the Enfold search won’t be compatible, we’ll remove it. You can add in an UberMenu search bar instead. */
    function remove_avia_search(){
    remove_filter( ‘wp_nav_menu_items’, ‘avia_append_search_nav’, 10, 2 );
    }
    add_action( ‘init’ , ‘remove_avia_search’ );

    Thanks
    Lyse

    #736782

    Hi,

    We need to take a closer look Please post us your login credentials (in the “private data” field), so we can take a look at your backend.

    Login credentials include:

    • The URL to the login screen.
    • A valid username (with full administration capabilities).
    • As well as a password for that username.
    • permission to deactivate plugins if necessary.

    Best regards,
    Vinay

    #736789

    Hi Vinay,

    You have permission to deactivate plugins if necessary.

    Please find login credentials in private area.

    Thank you
    Lyse

    #736805

    Hi!

    Please add the following to your functions.php

    add_filter('wp_nav_menu_items', 'do_shortcode');
    

    and let us know if that fixes the issue.

    Thanks a lot

    Best regards,
    Basilis

    #736819

    Hi Basilis,

    That added the search icon and box, but it does not display nicely. The CSS would need to be tweaked. If you can help me with doing this that would be great.

    Thanks
    Lyse

    #736823

    Hey!

    That is an extra work and depends on what you need to do.
    A better case scenario to that, is to hire a freelancer who would help you with any customisations you need, to make it look as you prefer.
    Let us know if we can do anything else to help you out, regarding our theme.

    Thanks a lot

    Best regards,
    Basilis

    #736840

    Hi Basilis,

    If I knew the class I could do it myself….I need to resize the icon and adjust the padding

    Thanks
    Lyse

    #737133

    Hi,

    Please try adding this code to the Quick CSS section under Enfold > General Styling or to your child themes style.css file:

    #menu-item-20684 {
    	margin-top: -11px;
    }
    .header_color input[type='submit']{
    	border:none!important;
    }
    

    To find the class name of an element please right click on the element and inspect. This will open chrome developer window and give you access to the html source code and class names of the element :)

    Best regards,
    Vinay

    #737361

    Hi Vinay,

    Worked perfectly with margin-top of -13px.

    Thank you so much for this.
    Lyse

Viewing 11 posts - 1 through 11 (of 11 total)
  • The topic ‘Move Search Icon to Secondary Menu’ is closed to new replies.