Start typing to see suggestions. Use arrow keys to navigate, Enter to select.

login

Kirby controller

Source: /controllers/login.php
Template: login

Description

Provides template variables for the login page's two-step authentication flow.
Manages auth mode state (login vs verify), error handling, and form data persistence.

Template variables

Variable Type Description
$mode String Current auth step ('login' or 'verify')
$error array Validation errors keyed by field name
$errorState bool Whether any errors exist
$hasError callable Closure to check if field has error - $hasError('email')
$fieldError callable Closure to get field's error message - $fieldError('email')
$formData Array Previously submitted form values for repopulation

Usage

This controller provides template variables for the login template.
Variables are available in the template file templates/login.php.


Source: /controllers/login.php