floriankarsten / kirby-plausible
0.2.3
2024-07-29 12:55 UTC
Requires
- getkirby/cms: ^4.0.0
- getkirby/composer-installer: ^1.1
README
这是一个简单的插件,它为 Kirby 控制面板和前端片段提供 Plausible iframe 面板视图。
安装
composer require floriankarsten/kirby-plausible
或从发布版下载
如何使用
- 创建共享链接 https://#/docs/shared-links
- 在 config.php 中设置
floriankarsten.plausible.sharedLink
// config/config.php 'floriankarsten.plausible' => [ // Required 'sharedLink' => 'https://#/share/yourwebsiteurl.com?auth=Jz0mCWTPu5opXi0sAgRrq', // Optional: The value that will be set in data-domain attribute of <script> tag. 'domain' => 'test.com', // Defaults to $site->url() // Optional: To use a self-hosted Plausible instance // 'scriptHost' => 'https://plausible.example.com', // Optional: To use Plausible script extensions // 'scriptName' => 'plausible.outbound-links.exclusions' ];
- 将以下片段添加到您网站的
<head>
标签内。请注意,这不会为已登录用户或当 Kirby 处于调试模式时生成任何输出。<?php snippet('plausible'); ?>
如果没有 @garethworld 的慷慨聘请,这个插件就不会出现。他友好地雇佣了我来制作它,并希望将其发布到 Kirby 社区。Yaaaaay