Using fingerprint to keep front-end users logged in


I have a site which is only accessible by logging in. As the users need to scan QR-Codes to add more content to their account, I want them to stay logged in constantly.

I have come across multiple posts like this one that use the fingerprint method.

I can however not get it to work. When I paste

s::$fingerprint = function() {
    return 'lukas fingerprint';

into my config.php it gives me the following fatal error:
Fatal error: Uncaught Error: Access to undeclared static property: Kirby\Cms\S::$fingerprint in “URL”

I feel I am missing something obvious here, but cannot figure out what. Do I need to put the fingerprint method anywhere first or is it already implemented with the kirby install?

The rest of my config.php file looks like this:

return [
    'debug' => true,
    'scssNestedCheck' => true,
    'routes' => [
     ], ...

You are trying to use Kirby 2 settings. Have a look at session config settings

Ah, that makes sense. So I guess what I want is to have a “keep me logged in” checkbox for the front-end user login-page as well in some kind of form. Where can I find information on how to do something like that?

Thank you!

And session | Kirby CMS

1 Like