From: Jean-Philippe Lang Date: Wed, 5 Sep 2007 20:13:06 +0000 (+0000) Subject: Search field automatically focused. X-Git-Tag: 0.6.0~175 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=0803e6fcaabe15f3e87c44f0404de4be09484b8e;p=redmine.git Search field automatically focused. git-svn-id: http://redmine.rubyforge.org/svn/trunk@707 e93f8b46-1217-0410-a6f0-8f06a7374b81 --- diff --git a/app/views/search/index.rhtml b/app/views/search/index.rhtml index 66b89743f..082527373 100644 --- a/app/views/search/index.rhtml +++ b/app/views/search/index.rhtml @@ -2,7 +2,8 @@
<% form_tag({}, :method => :get) do %> -

<%= text_field_tag 'q', @question, :size => 30 %> +

<%= text_field_tag 'q', @question, :size => 30, :id => 'search-input' %> +<%= javascript_tag "Field.focus('search-input')" %> <% if @project %> <%= check_box_tag 'scope[]', 'issues', (@scope.include? 'issues') %> @@ -62,4 +63,4 @@

<% end %> -<% end %> \ No newline at end of file +<% end %>