Mark blogs older than a year as outdated
parent
05b03c737c
commit
a4726731ed
|
@ -202,6 +202,14 @@ other = "Objectives"
|
|||
[options_heading]
|
||||
other = "Options"
|
||||
|
||||
[outdated_page_message]
|
||||
other = "Kubernetes authors consider this page to be outdated because REASON. We suggest that you use more recent resources."
|
||||
[outdated_page_reason]
|
||||
other = "it is more than a year old"
|
||||
|
||||
[outdated_page_title]
|
||||
other = "Outdated page"
|
||||
|
||||
[post_create_issue]
|
||||
other = "Create an issue"
|
||||
|
||||
|
|
|
@ -9,4 +9,15 @@
|
|||
</p>
|
||||
</div>
|
||||
</section>
|
||||
{{ else if and (eq .Section "blog") .Date (.Date.Before (now.AddDate -1 0 0)) -}}
|
||||
{{ $title := .Param "outdated_page.title" | default (T "outdated_page_title") -}}
|
||||
{{ $msg := .Param "outdated_page.message" | default (T "outdated_page_message") -}}
|
||||
{{ $reason := .Param "outdated_page.reason" | default (T "outdated_page_reason") -}}
|
||||
{{ $msg = replaceRE "REASON" $reason $msg -}}
|
||||
<section id="deprecation-warning">
|
||||
<div class="content deprecation-warning pageinfo">
|
||||
<h3>{{ $title }}</h3>
|
||||
<p> {{ $msg }}</p>
|
||||
</div>
|
||||
</section>
|
||||
{{ end }}
|
Loading…
Reference in New Issue