/** * Set a javascript variable. * * @param string $var * The name of the variable. * @param mixed $value * The new value. */ public static function set($var, $value) { Data::setInPath($var, $value, self::$vars); }
/** * Gets a var from the returned data. * * Communicator data is wrapped in a 'data' field. * * @param $var * @return null */ function get($var) { if (!empty($this->results['data'])) { return Data::getFromPath($var, $this->results['data']); } }
/** * Remove a setting from the session. * * @param string $field * The field name */ public function unsetSetting($field) { Data::removeFromPath($field, $this->content); }