Skip to content

Commit ddf7520

Browse files
authored
Backport: Point the link in the supported/unsupported version header to home page for 404s (backport #11652) (#11684)
* Point the link in the supported/unsupported version header to home pa… (#11652) * Point the link in the supported/unsupported version header to home page for 404s Signed-off-by: Fanit Kolchina <kolchfa@amazon.com> * Point to the about page Signed-off-by: Fanit Kolchina <kolchfa@amazon.com> --------- Signed-off-by: Fanit Kolchina <kolchfa@amazon.com> (cherry picked from commit c5d8bca) * Fix version warning link in _includes/warning.html for 404 handling The version warning in 1.1 is in _includes/warning.html, not _layouts/default.html. This commit adds the proper 404 handling logic to the correct file. Signed-off-by: Claude <noreply@anthropic.com> Signed-off-by: Fanit Kolchina <kolchfa@amazon.com> * Restore _layouts/default.html to original state The version warning in 1.1 is in _includes/warning.html, not _layouts/default.html. Reverting the incorrect changes to default.html while keeping the correct fix in warning.html. Signed-off-by: Claude <noreply@anthropic.com> Signed-off-by: Fanit Kolchina <kolchfa@amazon.com> --------- Signed-off-by: Fanit Kolchina <kolchfa@amazon.com> Signed-off-by: Claude <noreply@anthropic.com>
1 parent 1ec395b commit ddf7520

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

_includes/warning.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
<p class="unsupported-version-warning">You're viewing version {{site.opensearch_major_minor_version}} of the OpenSearch documentation. This version is no longer maintained. For the latest version, see the <a href="{{ site.url }}/latest{{ page.url }}">current documentation</a>. For information about OpenSearch version maintenance, see <a href="https://opensearch.org/releases.html">Release Schedule and Maintenance Policy</a>.</p>
1+
<p class="unsupported-version-warning">You're viewing version {{site.opensearch_major_minor_version}} of the OpenSearch documentation. This version is no longer maintained. For the latest version, see the <a href="{% if page.url contains '404' %}{{ site.url }}/latest/about/{% else %}{{ site.url }}/latest{{ page.url }}{% endif %}">current documentation</a>. For information about OpenSearch version maintenance, see <a href="https://opensearch.org/releases.html">Release Schedule and Maintenance Policy</a>.</p>

0 commit comments

Comments
 (0)