-
AuthorPosts
-
February 12, 2014 at 6:39 am #222577
Hey Guys,
I’m hoping you can recommend options or potential solution. We have a store on a subdomain that isn’t part of the WP install. We need the results to show from both the main domain (Enfold installation), and the store on the shop subdomain.
How would you recommend we do this and use the existing search box or is it fairly simple to a new search box in place of the current one? I’m just not wanting to break the user experience stylistically, so I’d really like the results to be displayed in the current theme/skin.
Hoping you guys can help.
Thanks much!
Mark
February 13, 2014 at 1:30 am #223127Hello!
If the Shop is another WP installation it may be possible but that would require a heavy customization and unfortunately that’s beyond the scope of the support we can offer.
P.S. Take a look at this: https://swiftype.com/
Cheers!
JosueFebruary 14, 2014 at 3:23 am #223740Hey Josue,
Thanks very much for the info…swiftype would be perfect and allow me to index both domains, but can you give me some info on how I’d have the current search box use the swiftype embeddable code or place the swiftype code in the template?
Thanks much!
Mark
February 14, 2014 at 4:08 am #223744Hey!
In functions-enfold.php, around line 66, you’d put your custom form in HTML format there. It would be better to contact the Swiftype support if you decide to go with them.
Best regards,
JosueFebruary 14, 2014 at 5:05 am #223754Thanks, Josue – they provided me with the form code to insert into the footer that floats a search box in the footer area, but I’d really like it to appear in the header.
I assumed I could just paste their form code into the $items call around line 66…is that not the case?
$items .= '<li id="menu-item-search" class="noMobile menu-item menu-item-search-dropdown"><a href="?s=" rel="nofollow" data-avia-search-tooltip="'.$form.'" '.av_icon_string('search').'></a></li>';
Their floating code is:
<script type="text/javascript"> var Swiftype = window.Swiftype || {}; (function() { Swiftype.key = 'EeQjiyzuVo7taNSHZzYs'; Swiftype.inputElement = '#searchform input#s'; Swiftype.attachElement = '#searchform input#s'; /** DO NOT EDIT BELOW THIS LINE **/ var script = document.createElement('script'); script.type = 'text/javascript'; script.async = true; script.src = "//s.swiftypecdn.com/embed.js"; var entry = document.getElementsByTagName('script')[0]; entry.parentNode.insertBefore(script, entry); }()); </script> <style> #st-overlay-search-input { border: 0; padding: 0; width: 100%; } </style>
February 14, 2014 at 5:32 am #223760Hey!
I’m not sure because i haven’t used Swiftype with Enfold, but i think that code should be in a footer.php or header.php and you’d not need to edit functions-enfold.php. However it may requiere additional tweaking, like disabling the built-in ajax search functionality (you can do this by removing line 30 from js/avia.js).
If you need more assistance please contact one developer from Codeable or Microlancer, as i said in my first reply we can not help you here because it’s out of the scope of our support policy.
Regards,
JosueFebruary 14, 2014 at 5:41 am #223767This reply has been marked as private.February 14, 2014 at 5:47 am #223771Hi!
This will fix it (Quick CSS):
#top .main_menu .menu>li:last-child>a { padding-right: 13px !important; }
Cheers!
JosueFebruary 14, 2014 at 5:57 am #223774This reply has been marked as private.February 14, 2014 at 5:58 am #223776This reply has been marked as private.February 14, 2014 at 6:00 am #223779Hi!
You have a caching plugin activated, flush it and see if the code takes effect.
Best regards,
JosueFebruary 14, 2014 at 6:07 am #223782That did it – I had purged the index page, but apparently need to flush everything. Thanks much. Btw, if you all make a plugin that will search across multiple domains, that would be amazing! :-)
Thanks so much for the help and support. Appreciate you all!
February 14, 2014 at 6:20 am #223790Hehe, yeah it would. You are welcome, glad we could help you :)
Cheers!
Josue -
AuthorPosts
- The topic ‘Site Search Options’ is closed to new replies.