diff --git a/app/helpers/search_helper.rb b/app/helpers/search_helper.rb
index 75412c7..ed2f40b 100644
--- a/app/helpers/search_helper.rb
+++ b/app/helpers/search_helper.rb
@@ -26,7 +26,12 @@ module SearchHelper
result << '...'
break
end
- result << (i.even? ? h(words.length > 100 ? "#{words[0..44]} ... #{words[-45..-1]}" : words) : content_tag('span', h(words), :class => 'highlight'))
+ if i.even?
+ result << h(words.length > 100 ? "#{words[0..44]} ... #{words[-45..-1]}" : words)
+ else
+ t = (tokens.index(words.downcase) || 0) % 4
+ result << content_tag('span', h(words), :class => "highlight token-#{t}")
+ end
end
result
end
diff --git a/app/views/search/index.rhtml b/app/views/search/index.rhtml
index 4dc26af..4bf80f0 100644
--- a/app/views/search/index.rhtml
+++ b/app/views/search/index.rhtml
@@ -9,7 +9,7 @@
<% end %>
-<%= check_box_tag 'all_words', 1, @all_words %> <%= l(:label_all_words) %>