Skip to content

Commit

Permalink
The no-index functionality works only if the pages are allowed to be …
Browse files Browse the repository at this point in the history
…crawled (#461)

Closes #460

Signed-off-by: Alexander Schwartz <aschwart@redhat.com>
  • Loading branch information
ahus1 committed Apr 15, 2024
1 parent 167ae5f commit ded4c7d
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 9 deletions.
2 changes: 1 addition & 1 deletion pages/blog-archive.ftl
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<#import "/templates/template.ftl" as tmpl>

<@tmpl.page current="blog" title="Blog archive">
<@tmpl.page current="blog" title="Blog archive" noindex=true>

<div class="container mt-5 kc-article">
<h1>Blog Archive</h1>
Expand Down
7 changes: 1 addition & 6 deletions static/robots.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1 @@
User-agent: *
Disallow: /archive/
Disallow: /blog-archive.html
Disallow: /blog-archive
Disallow: /downloads-archive.html
Disallow: /downloads-archive
User-agent: *
6 changes: 4 additions & 2 deletions templates/documentation-11.ftl
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,10 @@

<#if archive>
<#assign docRoot = "${root}docs/${version.version}">
<#assign docApiRoot = "${root}docs-api/${version.version}">
<#else>
<#assign docRoot = "${root}docs/latest">
<#assign docApiRoot = "${root}docs-api/latest">
</#if>

<table class="table table-bordered table-striped">
Expand Down Expand Up @@ -106,7 +108,7 @@
<tbody>
<tr>
<td>
<a href="${root}docs-api/${version.version}/javadocs/index.html" target="_blank">
<a href="${docApiRoot}/javadocs/index.html" target="_blank">
JavaDoc
</a>
</td>
Expand All @@ -116,7 +118,7 @@
</tr>
<tr>
<td>
<a href="${root}docs-api/${version.version}/rest-api/index.html" target="_blank">
<a href="${docApiRoot}/rest-api/index.html" target="_blank">
Administration REST API
</a>
</td>
Expand Down

0 comments on commit ded4c7d

Please sign in to comment.