From ffd0a9c72c241eb089bcc63bf0e57a4b872144d4 Mon Sep 17 00:00:00 2001 From: Jean-Philippe Lang Date: Tue, 12 Apr 2011 19:22:44 +0000 Subject: [PATCH] Adds noindex,noarchive robots meta tag on form pages (#7582). git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@5443 e93f8b46-1217-0410-a6f0-8f06a7374b81 --- app/helpers/application_helper.rb | 4 ++++ app/views/issue_moves/new.rhtml | 3 +++ app/views/issues/edit.rhtml | 3 +++ app/views/issues/new.rhtml | 1 + app/views/wiki/edit.rhtml | 1 + 5 files changed, 12 insertions(+) diff --git a/app/helpers/application_helper.rb b/app/helpers/application_helper.rb index 8a41872df..9410e8dcf 100644 --- a/app/helpers/application_helper.rb +++ b/app/helpers/application_helper.rb @@ -900,6 +900,10 @@ module ApplicationHelper def favicon "" end + + def robot_exclusion_tag + '' + end # Returns true if arg is expected in the API response def include_in_api_response?(arg) diff --git a/app/views/issue_moves/new.rhtml b/app/views/issue_moves/new.rhtml index cd6044052..24d59aedc 100644 --- a/app/views/issue_moves/new.rhtml +++ b/app/views/issue_moves/new.rhtml @@ -74,3 +74,6 @@ <%= submit_tag l(:button_move_and_follow), :name => 'follow' %> <% end %> <% end %> +<% content_for :header_tags do %> + <%= robot_exclusion_tag %> +<% end %> diff --git a/app/views/issues/edit.rhtml b/app/views/issues/edit.rhtml index 97f26a205..f2c6024ba 100644 --- a/app/views/issues/edit.rhtml +++ b/app/views/issues/edit.rhtml @@ -1,3 +1,6 @@

<%=h "#{@issue.tracker.name} ##{@issue.id}" %>

<%= render :partial => 'edit' %> +<% content_for :header_tags do %> + <%= robot_exclusion_tag %> +<% end %> diff --git a/app/views/issues/new.rhtml b/app/views/issues/new.rhtml index 13992382f..867590fa2 100644 --- a/app/views/issues/new.rhtml +++ b/app/views/issues/new.rhtml @@ -23,4 +23,5 @@ <% content_for :header_tags do %> <%= stylesheet_link_tag 'scm' %> + <%= robot_exclusion_tag %> <% end %> diff --git a/app/views/wiki/edit.rhtml b/app/views/wiki/edit.rhtml index 2615075e2..5f47c3f8c 100644 --- a/app/views/wiki/edit.rhtml +++ b/app/views/wiki/edit.rhtml @@ -23,6 +23,7 @@ <% content_for :header_tags do %> <%= stylesheet_link_tag 'scm' %> + <%= robot_exclusion_tag %> <% end %> <% html_title @page.pretty_title %> -- 2.39.5