2005-01-30 04:17:02 +01:00
|
|
|
<% @title = "Search results for \"#{@params["query"]}\"" %>
|
2005-01-24 19:52:04 +01:00
|
|
|
|
2005-01-30 04:17:02 +01:00
|
|
|
<% unless @title_results.empty? %>
|
|
|
|
<h2><%= @title_results.length %> page(s) containing search string in the page name:</h2>
|
|
|
|
<ul>
|
|
|
|
<% for page in @title_results %>
|
2005-02-19 00:19:42 +01:00
|
|
|
<li>
|
2005-02-19 03:45:28 +01:00
|
|
|
<%= link_to page.plain_name, :web => @web.address, :action => 'show', :id => page.name %>
|
2005-02-19 00:19:42 +01:00
|
|
|
</li>
|
2005-01-30 04:17:02 +01:00
|
|
|
<% end %>
|
|
|
|
</ul>
|
|
|
|
<% end %>
|
|
|
|
|
|
|
|
|
|
|
|
<% unless @results.empty? %>
|
|
|
|
<h2> <%= @results.length %> page(s) containing search string in the page text:</h2>
|
2005-01-24 19:52:04 +01:00
|
|
|
<ul>
|
|
|
|
<% for page in @results %>
|
2005-02-19 00:19:42 +01:00
|
|
|
<li>
|
2005-02-19 03:45:28 +01:00
|
|
|
<%= link_to page.plain_name, :web => @web.address, :action => 'show', :id => page.name %>
|
2005-02-19 00:19:42 +01:00
|
|
|
</li>
|
2005-01-24 19:52:04 +01:00
|
|
|
<% end %>
|
|
|
|
</ul>
|
2005-01-30 04:17:02 +01:00
|
|
|
<% end %>
|
2005-01-24 19:52:04 +01:00
|
|
|
|
2005-01-30 04:17:02 +01:00
|
|
|
<% if (@results + @title_results).empty? %>
|
|
|
|
<h2>No pages contains "<%= @params["query"] %>" </h2>
|
|
|
|
<p>
|
|
|
|
Perhaps you should try expanding your query. Remember that Instiki searches for entire
|
|
|
|
phrases, so if you search for "all that jazz" it will not match pages that contain these
|
|
|
|
words in separation—only as a sentence fragment.
|
|
|
|
</p>
|
|
|
|
<p>
|
|
|
|
If you're a high-tech computer wizard, you might even want try constructing a Ruby regular
|
|
|
|
expression. That's actually what Instiki uses, so go right ahead and flex your
|
|
|
|
"[a-z]*Leet?RegExpSkill(s|z)"
|
|
|
|
</p>
|
2005-01-24 19:52:04 +01:00
|
|
|
<% end %>
|