Add a variable that will be globally accessible in the template

@param string $key
@param $value
516547
protected function addGlobal(string $key, $value)
    {
        $template = $this->getContext()->getTemplateEngine();
        $template->addGlobal($key, $value);
    }
522903
function set($key, $value) {
        if(!$this->enabled) {
            return $this;
        }
        
        parent::set($key, $value);
        return $this;
    }
713522
protected function __storeData($key, $value = null)
    {
        if (property_exists($this, $key)) {
            $this->$key = $value;
        }
        else {
            parent::__storeData($key, $value);
        }
    }
961049
public function set($key, $value)
    {
        array_set($this->settings,$key,$value);
        $this->save($this->path, $this->filename);
        $this->load($this->path, $this->filename);
    }
635954
public function shareData($key, $value= null)
    {
        if (is_array($key)) {
            foreach  ($key as $variableName => $variableValue) {
                $this->templateRenderer->setData($variableName, $variableValue);
            }
            return $this;
        }

        $this->templateRenderer->setData($key, $value);
        return $this;
    }
213157
public function set($key, $value)
    {
        $keys = explode('.', $key);
        $key_string = '';
        foreach ($keys as $i => $_key) {
            $key_string = $key_string . ((is_numeric($_key) || $_key === '') ? "[{$_key}]" : "['{$_key}']");
        }
        $script = sprintf('$this->_params%s = $value;', $key_string);
        eval($script);
    }
1309254
public function offsetSet($key, $value){
        if ( is_array($value) )
          parent::offsetSet($key, new static($value));
        else
          parent::offsetSet($key, $value);
    }
397509
public function addCacheTag($key, $value)
    {
        if ($this->runtimeContentCache->getEnableContentCache() === false) {
            return;
        }
        $this->runtimeContentCache->addTag($key, $value);
    }
153003
public static function setUrlParameter(string $key, $value=null) :void {
		
		// set the value
		self::$_get[$key] = $value;
		
	}
928106
public function cache($key, $value)
    {
        $this->log(
            Mustache_Logger::WARNING,
            'Template cache disabled, evaluating "{className}" class at runtime',
            array('className' => $key)
        );
        eval('?>' . $value);
    }
952106
public function setVariable($key, $value) {
        $this->_content = str_replace('#' . $key . '#', (string)$value, $this->_content);
        return $this;
    }
1012755
public function addGlobalCustomArg($key, $value = null)
    {
        if ($key instanceof CustomArg) {
            $custom_arg = $key;
            $this->custom_args[$custom_arg->getKey()]
                = $custom_arg->getValue();
            return;
        }
        $this->custom_args[$key] = (string)$value;
    }
953477
public function push($key, $value)
    {
        $config = $this->get($key);

        $this->setSingleItem($key, \array_push($config, $value));
    }
306001
public function set($key, $value = null)
    {
        if (is_array($key)) {
            $key = $this->flattenArray($key);
            $this->settings = array_merge($this->settings, $key);
        } else {
            $this->settings[$key] = $value;
        }
    }
1182349
public function setAttribute($key, $value)
    {

        // if the value is already set, throw an exception
        if (isset($this[$uid = $this->maskKey($key)])) {
            throw new \Exception(
                sprintf('A value with key %s has already been set in application %s', $key, $this->getName())
            );
        }

        // append the value to the application
        $this[$uid] = $value;
    }
568718
public static function set( $key, $value = null )
    {
        Option::set( static::$_options, static::_getKeyTag( $key ), $value );
    }
1290848
public function addValue(string $key, string $value) : void
    {
        $this->map[$key] = $value;
    }