Skip to content

Commit 9da3cbc

Browse files
committed
Adds crawler directives to result and record pages
Why are these changes being introduced: * It doesn't make sense to have search engines index and follow links from our own results and record pages Relevant ticket(s): * https://mitlibraries.atlassian.net/browse/TIMX-476 How does this address that need: * adds meta robots tag with noindex, nofollow rules
1 parent 2b597ac commit 9da3cbc

File tree

2 files changed

+8
-0
lines changed

2 files changed

+8
-0
lines changed

app/views/record/view.html.erb

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,9 @@
11
<%= content_for(:title, record_page_title(@record)) %>
22

3+
<% content_for :additional_meta_tag do %>
4+
<meta name="robots" content="noindex, nofollow" />
5+
<% end %>
6+
37
<%= render(partial: 'shared/error', collection: @errors) %>
48

59
<%= render(partial: 'shared/site_title') %>

app/views/search/results.html.erb

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,9 @@
11
<%= content_for(:title, results_page_title(@enhanced_query)) %>
22

3+
<% content_for :additional_meta_tag do %>
4+
<meta name="robots" content="noindex, nofollow" />
5+
<% end %>
6+
37
<div class="space-wrap">
48

59
<%= render partial: "shared/site_title" %>

0 commit comments

Comments
 (0)