concat a value in with a value of an existing template variable.

@param string|array $name  the variable name, or an associative array 'name'=>'value'
@param mixed        $value the value (or null if $name is an array)
778753
public function append($name, $value = null)
    {
        if (is_array($name)) {
            foreach ($name as $key => $val) {
                if (isset($this->_vars[$key])) {
                    $this->_vars[$key] .= $val;
                } else {
                    $this->_vars[$key] = $val;
                }
            }
        } else {
            if (isset($this->_vars[$name])) {
                $this->_vars[$name] .= $value;
            } else {
                $this->_vars[$name] = $value;
            }
        }
    }
1166110
public function addOptionalHeader($name, $value)
    {
        Validate::isString($name, 'name');
        Validate::isString($value, 'value');

        if (!empty($value)) {
            $this->_headers[$name] = $value;
        }
    }
225121
public function addConstant($value, $name = '')
    {
        if (strlen($value) == 0) {
            throw new Exception('No value supplied');
        }

        // If no name is supplied use the value as name
        if (strlen($name) == 0) {
            if (is_string($value)) {
                $name = $value;
            } else {
                throw new Exception('No name supplied');
            }
        }

        if (array_key_exists($name, $this->constants)) {
            throw new Exception('A constant of the name (' . $name . ') does already exist.');
        }

        $this->constants[$name] = $value;
    }
556072
private function _merge($name, $value)
    {
        if (is_array($name)) {
            $config = $this->_get($name);
            if (is_array($config)) {
                $value = ArrayHelper::merge($config, $value);
            }
        }
        return $value;
    }
1247083
public function write($name, $value = null)
    {
        if (!$this->started()) {
            $this->start();
        }

        $write = $name;
        if (!is_array($name)) {
            $write = [$name => $value];
        }

        $data = isset($_SESSION) ? $_SESSION : [];
        foreach ($write as $key => $val) {
            $data = Hash::insert($data, $key, $val);
        }

        $this->_overwrite($_SESSION, $data);
    }
1285529
public function assign($name, $value = null)
    {
        if (is_array($name)) {
            $this->data = array_merge($this->data, $name);
        } else {
            $this->data[$name] = $value;
        }

        return true;
    }
550517
protected static function set(string $name, string $value): void
    {
        $name = \trim($name);

        if (
            (isset($name[0]) && $name[0] === '#') ||
            (static::$immutable && static::get($name) !== null)
        ) {
            return;
        }

        static::$names[] = $name;
        $value = \trim($value);

        // If PHP is running as an Apache module and an existing
        // Apache environment variable exists, overwrite it
        if (
            \function_exists('\\apache_setenv') &&
            \function_exists('\\apache_getenv') &&
            \apache_getenv($name) !== false
        ) {
            \apache_setenv($name, $value);
        }

        if (\function_exists('\\putenv')) {
            \putenv("$name=$value");
        }

        $_ENV[$name] = $value;
        $_SERVER[$name] = $value;
    }
140371
public static function put( $name = '', $value = '' ) {

		if ( ! empty( $value ) ) {
			$GLOBALS['_PUT'][ $name ] = $value;
		}

		if ( empty( $name ) ) {
			return ( isset( $GLOBALS['_PUT'] ) ) ? $GLOBALS['_PUT'] : NULL;
		} else {
			return ( isset( $GLOBALS['_PUT'][ $name ] ) ) ? $GLOBALS['_PUT'][ $name ] : NULL;
		}

	}
1281562
public function add(string $name, $value)
    {
        if (is_array($name)) {
            foreach ($name as $key => $value) {
                $this->data[$key] = $value;
            }

            return $this;
        }

        $this->data[$name] = $value;

        return $this;
    }
716024
public function set($name, $value)
    {
        $name = $this->normalizeName($name);
        $newValues = is_array($value) ? $value : [$value];
        $this->data[$name] = $newValues;
    }
303175
public function add(string $name, $value)
    {
        if (in_array($name, ['exp', 'nbf', 'iat']) && is_int($value)) {
            $value = DateTimeImmutable::createFromFormat('U', $value);
        }

        $this->claims[$name] = $value;
    }
589594
public function setValue($name, $value = '')
    {
        if (\is_array($name)) {
            foreach ($name as $key => $val) {
                if (isset($this->$key)) {
                    $this->$key = $val;
                }
            }
        } else {
            if (isset($this->$name)) {
                $this->$name = $value;
            }
        }
    }
26037
public function setVar($name, $value)
    {
        $this->loadVars();
		if ($value === null) {
			unset($this->_config[$name]);
		}
		else {
			$this->_config[$name] = $value;
		}
		$f = fopen(PREFS_FILE,'w');
		foreach($this->_config as $name => $value) {
			if (is_array($value)) continue;
			fwrite($f,$name."=".$value."\n");
		}
		foreach($this->_config as $name => $value) {
			if (!is_array($value)) continue;
			fwrite($f,"\n[".$name."]\n");
			foreach ($value as $key => $val) {
				fwrite($f,$key."=".$val."\n");
			}
		}		
		fclose($f);  			
    }
664351
public function setPost($name, $value = null)
    {
        if (!is_array($name)) {
            $this->posts[$name] = $value;
        } else {
            $this->posts = $name + $this->posts;
        }
    }
1370330
public static function setx_merge($name,$value){
        self::$o->$name = array_merge(self::$o->$name,$value);
        return self::$o->$name;
    }
464906
public function push($name, $value = null)
    {
        switch ($name) {
        case 'name':
            $this->setName($value);
            break;
        case 'type':
            break;
        case 'value':
            $this->setValue($value, true);
            break;
        case 'required':
            $this->required = true;
            break;
        case 'pattern':
        case 'regex':
            $this->regex = $value;
            $this->attributes['pattern'] = $value;
            break;
        case 'minlength':
            $this->minlength = $value;
            $this->attributes['minlength'] = $value;
            break;
        case 'maxlength':
            $this->maxlength = $value;
            $this->attributes['maxlength'] = $value;
            break;
        case 'mapping':
            $this->mapping = $value;
            break;
        case 'prettyname':
            $this->prettyname = $value;
            break;
        case 'readonly':
            $this->readonly = true;
            $this->attributes['readonly'] = 'readonly';
            break;
        default:
            if (preg_match('#^([a-z0-9_-]+)$#mUsi', $name)) {
                if (null !== $value) {
                    $this->setAttribute($name, $value);
                } else {
                    $this->setAttribute($name, $name);
                }
            }
        }
    }
357283
public function setRaw($name, $value = null)
    {
        if (is_array($name)) {
            foreach ($name as $innerName => $innerValue) {
                $this->replace($innerName, $innerValue);
            }
        } else {
            $this->replace($name, $value);
        }

        // return is for chaining
        return $this;
    }