Created
September 17, 2016 05:46
-
-
Save unofficialshopify/23a0e9a4e9ebeaf9007bb59ab92b4456 to your computer and use it in GitHub Desktop.
How to add search bar or box in shopify
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 action="/search" method="get" class="input-group search-bar" role="search"> | |
{% comment %}<input type="hidden" name="type" value="product">{% endcomment %} | |
<input type="search" name="q" value="{{ search.terms | escape }}" placeholder="{{ 'Search'}}" class="input-group-field" aria-label="{{ 'Search'}}"> | |
<span class="input-group-btn"> | |
<button type="submit" class="btn icon-fallback-text"> | |
<span class="icon icon-search" aria-hidden="true"></span> | |
<span class="fallback-text">{{ 'general.search.submit' | t }}</span> | |
</button> | |
</span> | |
</form> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment