Gdn_Session::setPublicStash PHP Method

setPublicStash() public method

Sets a public stash value.
public setPublicStash ( string $name, mixed $value ) : Gdn_Session
$name string The key of the stash value.
$value mixed The value of the stash to set. Pass null to clear the key.
return Gdn_Session $this Returns $this for chaining.
    public function setPublicStash($name, $value)
    {
        if ($value === null) {
            $this->stash('@public_' . $name, '', true);
        } else {
            $this->stash('@public_' . $name, $value, false);
        }
        return $this;
    }