bnomei / kirby3-page-sqlite
Kirby 3 Plugin to cache the content file using SQLite
Fund package maintenance!
bnomei
Patreon
buymeacoff.ee/bnomei
paypal.me/bnomei
Installs: 53
Dependents: 0
Suggesters: 0
Security: 0
Stars: 0
Watchers: 2
Forks: 0
Open Issues: 0
Type:kirby-plugin
Requires
- php: >=7.2.0
- getkirby/composer-installer: ^1.1
Requires (Dev)
- getkirby/cms: ^3.2
- php-coveralls/php-coveralls: ^2.1
- phpunit/phpunit: ^8.3
README
ARCHIVED
use Kirby3 Boost instead
Kirby 3 Page SQLite
Kirby 3 Plugin to cache the content file using SQLite
Commercial Usage
This plugin is free (MIT license) but if you use it in a commercial project please consider to
Installation
- unzip master.zip as folder
site/plugins/kirby3-page-sqlite
or git submodule add https://github.com/bnomei/kirby3-page-sqlite.git site/plugins/kirby3-page-sqlite
orcomposer require bnomei/kirby3-page-sqlite
Usage
To use this plugin create Page-Models and extend the \Bnomei\SQLitePage
class. This will read and write a copy of your Content-File to and from a SQLite database. The plugin will automatically keep track of the modified timestamp.
site/models/example.php
<?php class ExamplePage extends \Bnomei\SQLitePage { // that's it. all done. 👍 }
TIP: If you set Kirbys global debug option to
true
all cached Content-Files will be flushed.
site/templates/example.php
<?php /** @var ExamplePage $page */ $checkIfContentFileIsSQLiteCached = $page->isSQLitePage(); // bool
Settings
bnomei.page-sqlite. | Default | Description |
---|---|---|
file | callback |
Dependencies
- PHP SQLite extension
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
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.