Skip to content

Kirby 4.4.1

$visitor->acceptedLanguage()

Sets the accepted language if provided or returns the user's accepted language otherwise

$visitor->acceptedLanguage(?string $acceptedLanguage = null): Kirby\Toolkit\Obj|Kirby\Http\Visitor|null

Parameters

Name Type Default
$acceptedLanguage string|null null

Return type

Kirby\Toolkit\Obj|Kirby\Http\Visitor|null

This method does not modify the existing $visitor object but returns a new object with the changes applied. Learn more →

Parent class

Kirby\Http\Visitor