thepoddi / kirby3-seokit
Kirby 3 SEO 工具包,包括 sitemap.xml 和 robotx.txt
Requires
This package is auto-updated.
Last update: 2024-09-07 07:12:09 UTC
README
Kirby 3 SEO 插件。
第一步,此插件将 Kirby 2 插件 Kirby 插件:Robots 和 Kirby 插件:Sitemap 合并为一个针对 Kirby 3 的 SEO 工具包。更多功能,如 Meta 标签、结构化数据和通过面板的选项,将在我的待办事项列表中。
安装
下载
下载并将此存储库复制到 /site/plugins/seokit
。
Git 子模块
将此存储库作为子模块包含。
git submodule add https://github.com/thepoddi/kirby3-seokit.git site/plugins/seokit
Composer
composer require thepoddi/kirby3-seokit
用法
此插件将 robots 文件设置为 /robots.txt
,将 sitemap 文件设置为 /sitemap.xml
作为 Kirby 路由。实际上不会生成任何文件。
配置
您可以通过 Kirby 的配置文件 /site/config/config.php
编辑多个配置选项。
robots.txt
忽略页面
通过 URI 忽略特定页面 - 示例:'blog/my-article'。(数组)默认:错误
'thepoddi.seokit.robots.disallow.pages' => array( 'error' ),
通过预期模板忽略页面。(数组)默认:错误
'thepoddi.seokit.robots.disallow.templates' => array( 'error' ),
忽略未列出页面。(布尔值)默认:true
'thepoddi.seokit.robots.disallow.unlisted' => true,
设置 sitemap 文件
在 robots.txt 中设置 sitemap 文件。(字符串)默认:sitemap.xml
'thepoddi.seokit.robots.sitemap' => 'sitemap.xml',
sitemap.xml
忽略页面
通过 uid 忽略页面。(数组)默认:错误
'thepoddi.seokit.sitemap.ignore.pages' => array( 'error' ),
通过预期模板忽略页面。(数组)默认:错误
'thepoddi.seokit.sitemap.ignore.templates' => array( 'error' ),
忽略未列出页面。(布尔值)默认:true
'thepoddi.seokit.sitemap.ignore.unlisted' => true,
优先页面
通过 uid 设置高优先级页面。(数组)默认:home
'thepoddi.seokit.sitemap.important.pages' => array( 'home' ),
通过预期模板设置高优先级页面。(数组)默认:home
'thepoddi.seokit.sitemap.important.templates' => array( 'home' ),
包含图像 sitemap
在 sitemap 中包含图像标签 Google 图像 Sitemap。(布尔值)默认:true
'thepoddi.seokit.sitemap.include.images' => true,
作者
Patrick Schumacher - GitHub · 网站
许可证
本项目采用 MIT 许可证 - 请参阅 LICENSE 文件以获取详细信息。