search form not working properly
-
I’ve got a search form in the main nav of a site I’m building. For some reason, it’s not fully working. The search will only work if you try to pull up an exact page title. If you search for a name or a term on a page, it does not turn up any results. For example, there is a person named Beth listed on the About page, but when you search “Beth” in the search bar, it does not pull up any results.
What could be the issue?
Here’s a link to my test site: http://test.cgla.net/. It’s got a password on it, just so the client can’t see it yet. It’s Cabrini2017!
Here’s the code from header.php for the search form:
<div class="search-dropdown" style="display: block;"> <form method="get" id="searchform" action="<?php echo site_url(); ?>"> <input type="text" class="field" name="s" id="s" placeholder="What are you looking for?"> <button type="submit" class="submit" name="submit" id="searchsubmit"><i class="fa fa-search fa-lg"></i></button> </form> </div>
Here’s the jQuery I’m using for the hide&show feature:
/*Hide&Show search bar in header*/ $(document).ready(function(){ $("#searchform").hide(); $(".search-trigger").click(function(){ $("#searchform").fadeToggle(200); }); });
Viewing 4 replies - 1 through 4 (of 4 total)
Viewing 4 replies - 1 through 4 (of 4 total)
- The topic ‘search form not working properly’ is closed to new replies.