Created
June 23, 2017 13:57
-
-
Save speedracr/af50d364aaaedef5a6f6b7b14249df38 to your computer and use it in GitHub Desktop.
Rails search field
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<%= form_tag('/search', local: true, method: :get, class: 'form-inline' ) do %> | |
<%= text_field_tag(:q, nil, data: { behavior: 'autocomplete' }, placeholder: 'Search', class: 'form-control mr-sm-2') %> | |
<%= button_tag('Search', class: 'btn btn-outline-success my-2 my-sm-0', type: 'submit') %> | |
<% end %> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment