2012-10-11 17:41:49 -04:00
|
|
|
.search
|
2012-11-20 16:05:15 -05:00
|
|
|
= form_tag search_path, method: :get, class: 'navbar-form pull-left' do |f|
|
2012-10-11 17:41:49 -04:00
|
|
|
= text_field_tag "search", nil, placeholder: "Search", class: "search-input"
|
|
|
|
|
|
|
|
:javascript
|
|
|
|
$(function(){
|
|
|
|
$("#search").autocomplete({
|
|
|
|
source: #{raw search_autocomplete_source},
|
|
|
|
select: function(event, ui) { location.href = ui.item.url }
|
|
|
|
});
|
|
|
|
});
|