zdarkmind94 Posted September 16, 2014 Share Posted September 16, 2014 Hello ,how can I include functionality for wordpress search on this static Markup: <div class="medium-4 columns sidebar"> <div class="row search"> <div class="small-12 columns"> <div class="row collapse"> <div class="small-8 columns"> <input type="text" placeholder="Cauta"> </div> <div class="small-2 columns end"> <a href="#" class="button postfix search_button"><i class="fa fa-search fa-lg"></i></a> </div> </div> </div> </div> Link to comment Share on other sites More sharing options...
justsomeguy Posted September 16, 2014 Share Posted September 16, 2014 Searching is dynamic, not static. A text field and link isn't a search engine, it's just a form (ideally, that link would be an actual submit button inside a form as well). The text field also needs a name or ID. If that link is supposed to search then I assume that they use Javascript to add a click handler to the link to submit the text to the server for searching. Link to comment Share on other sites More sharing options...
zdarkmind94 Posted September 17, 2014 Author Share Posted September 17, 2014 <div class="row search"> <div class="small-12 columns"> <div class="row collapse"> <form action="<?php echo home_url( '/' ); ?>" method="get"> <div class="small-8 columns field"> <input type="text" id="search" placeholder="Cauta" name="s" value="<?php the_search_query(); ?>" /> </div> <div class="small-2 end columns "> <button type="submit" id="search-button" class="postfix button"><i class="fa fa-search fa-lg"></i> </button> </div> </form> </div> </div> </div> Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now