Robots for Kirby CMS
Switch branches/tags
Nothing to show
Clone or download
Latest commit 8bb2b89 Oct 4, 2018
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
docs Version 0.2 Feb 22, 2017
vendor kirby 3 rewrite Jul 23, 2018
composer.json kirby 3 rewrite Jul 23, 2018
config.php kirby 3 rewrite Jul 23, 2018
index.php kirby 3 rewrite Jul 23, 2018
readme.md Version 0.2 Feb 22, 2017

readme.md

Kirby Robots Writer

Version 0.2

Control your robots.txt file through a config.php value.

Installation instructions

Setup

Into your config.php:

c::set('robots.txt', '
User-agent: *
Disallow: /
Sitemap: https://example.com/sitemap.xml
');

robots.txt output:

User-agent: *
Disallow: /
Sitemap: https://example.com/sitemap.xml

Alternative solution - Snippet

Make sure your snippet exists and is registered:

c::set('robots.txt', snippet('robots.txt', [], true));

Alternative solution - Site

Make sure you have a field called robots in site.

c::set('robots.txt', site()->robots());

Changelog

0.2

  • Complete rewrite. Made it much simpler.

0.1

  • Initial release

Requirements

Disclaimer

This plugin is provided "as is" with no guarantee. Use it at your own risk and always test it yourself before using it in a production environment. If you find any issues, please create a new issue.

License

MIT

It is discouraged to use this plugin in any project that promotes racism, sexism, homophobia, animal abuse, violence or any other form of hate speech.

Credits