Viewing 7 posts - 1 through 7 (of 7 total)
  • Author
    Posts
  • #522359

    Hi there. I’ve been trying to move the search form (not just the magnifying glass with the popup form) to #header_meta, let’s say, by the phone number area on the right but I’m having limited success. It looks like it will take a fair amount of CSS to make this work. Is there a way that’s currently supported by the theme that will make this work with minimal coding?

    My apologies in advance if this has been answered elsewhere. I’ve spent quite a bit of time searching…

    #522389

    Hey Kevin!

    Please add following code to functions.php file in Appearance > Editor

    add_shortcode('avia_search', 'get_search_form');

    and then go to Appearance > Menus and add a new link and add following into navigation label in your Enfold secondary menu

    [avia_search]

    Regards,
    Yigit

    #522437

    Sadly, this didn’t work. See the website in Private Content. The shortcode doesn’t get processed and just displays as text. I’ve tried it with or without a URL attached to it and it does the same thing either way. Is there something special I have to do to make the wa

    FYI, I’m doing this in a child theme if it matters.

    Any idea why this didn’t work?

    #522676

    Hi!

    Can you please try inserting the shortcode into phone info field in Enfold theme options > Header > Extra Elements?

    Cheers!
    Yigit

    #522698

    Doing so inserts the search box but breaks the layout. If you search for “leap” you’ll see that the search results preview also totally breaks the layout of the header when it shows.

    #523053

    Hi!

    Do you mind creating a temporary admin login and posting it here privately so we can look into it?

    Best regards,
    Yigit

    #523120

    Ultimately I was able to get this working on my own. I replaced your line of code with…

    add_shortcode('avia_search', 'pwm_append_search_nav'); 
    function pwm_append_search_nav(){
    	return get_search_form( false );	
    }

    …and inserted it into the phone field in Theme Options > Header. Then, I tinkered with the CSS quite a bit until I got it to display correctly. There was too much to put the details here. In the end, though, it’s working. I really appreciate your help.

    Thanks!
    kcm

Viewing 7 posts - 1 through 7 (of 7 total)
  • The topic ‘Search form in #header_meta’ is closed to new replies.