$visitor->ip()
Sets the ip address if provided or returns the ip of the current visitor otherwise
$visitor->ip(string|null $ip = null): Kirby\Http\Visitor|string|null
Parameters
Name | Type | Default |
---|---|---|
$ip | string ornull |
null
|
Return types
Kirby\Http\Visitor
orstring
ornull
This method modifies the existing $visitor
object it is applied to and returns it again.