pub / newsplanet

Planet-Style Newsfeed generated with perlanet
git clone https://src.jayvii.de/pub/newsplanet.git
Home | Log | Files | Exports | Refs | README | RSS

commit ca5e1400cfbce1c7c60d49ae540f2a09bc09e926
parent 2adc8b22673206db7adc5cb101fd97995b6228b1
Author: JayVii <jayvii[AT]posteo[DOT]de>
Date:   Sun, 23 Mar 2025 11:47:23 +0100

feat: ask bots/crawlers not not index newsplanet

Diffstat:
Mindex.php | 1+
Arobots.txt | 7+++++++
Mtemplate.tt | 4+++-
3 files changed, 11 insertions(+), 1 deletion(-)

diff --git a/index.php b/index.php @@ -19,6 +19,7 @@ <link rel="stylesheet" type="text/css" href="assets/css/custom.css"> <link crossorigin="use-credentials" rel="manifest" href="manifest.json"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> + <meta name="robots" content="noindex"> </head> <body> diff --git a/robots.txt b/robots.txt @@ -0,0 +1,7 @@ +# Allow all bots to poll the RSS & OPML endpoints +User-Agent: * +Allow: /*.xml$ + +# Disallow all bots anywhere on the site +User-agent: * +Disallow: / diff --git a/template.tt b/template.tt @@ -24,6 +24,7 @@ <link rel="alternate" title="[%feed.title %]" type="application/atom+xml" href="rss.xml"> <link crossorigin="use-credentials" rel="manifest" href=<!--MANIFEST-->> <meta name="viewport" content="width=device-width, initial-scale=1.0"> + <meta name="robots" content="noindex"> </head> <body onload="check_articles();"> @@ -73,7 +74,7 @@ [% FOREACH entry IN feed.entries %] <section data="[% entry.issued | html %]"> <h3> - <a href="[% entry.link | url | html %]" target="_blank"> + <a href="[% entry.link | url | html %]" target="_blank" rel="nofollow"> [% entry.title | html %] </a> </h3> @@ -89,6 +90,7 @@ <a class="button" target="_blank" + rel="nofollow" href="[% entry.link | url | html %]" style="width:auto;min-width:65px;" >