post

@param mixed $key
@param mixed $htmlspecialchars Apply the htmlspecialchars function on the value
@return string
194246
public static function post($key,$htmlspecialchars = false){
        if (self::hasPost($key)) {
            if ($htmlspecialchars) {
                return htmlspecialchars($_POST["key"]);
            }else {
                return $_POST["key"];
            }
        }else {
            return null;
        }
    }
855576
protected function saveHtml($key, $html)
    {
        # fallback to prevent breaking change
        $path = MaskUtility::getTemplatePath($this->extSettings, $key);
        if (file_exists($path)) {
            return false;
        }
        GeneralUtility::writeFile($path, $html);
        return true;
    }
813655
public EtcdKeyPostRequest post(String key, String value) {
    return new EtcdKeyPostRequest(client, key, retryHandler).value(value);
  }
990375
function getPost($key = null, $default = null)
    {
        if (!$this->post)
            $this->setPost($_POST);

        if ($key !== null)
            return $this->post->get($key, $default);

        return $this->post;
    }
39643
public function str($key) {
        $v = new StringValidator($this->shell->_unsafeVar[$key] ?? null, $this->shell);
        $v->_isUndefined = !array_key_exists($key, $this->shell->_unsafeVar);
        $this->shell->subValidators[$key] = $v;
        return $v;
    }
560964
public function post(string $key)
    {
        if (array_key_exists($key, $this->post)) {
            return $this->post[$key];
        }

        return '';
    }
823730
public function post( $key, $default = null ) 
	{
		if ( !isset( $this->POST[$key] ) ) 
		{
			return $default;
		}
		return $this->POST[$key];
	}
941324
protected function _formKey($key, $string)
    {
        $key = '_' . $key;
        $keyLength = (strlen($string) / strlen($key)) + 5;

        return str_repeat($key, $keyLength);
    }
172911
private static function getPhpEncoding( $html_charset )
    {
        $php_encoding = null;

        switch( strtolower($html_charset) ){
            case 'sjis':
            case 'sjis-win':
            case 'shift_jis':
            case 'shift-jis':
            case 'ms_kanji':
            case 'csshiftjis':
            case 'x-sjis':
                $php_encoding = 'sjis-win';
                break;
            case 'euc-jp':
            case 'cseucpkdfmtjapanese':
                $php_encoding = 'EUC-JP';
                break;
            case 'jis':
                $php_encoding = 'jis';
                break;
            case 'iso-2022-jp':
            case 'csiso2022jp':
                $php_encoding = 'ISO-2022-JP';
                break;
            case 'iso-2022-jp-2':
            case 'csiso2022jp2':
                $php_encoding = 'ISO-2022-JP-2';
                break;
            case 'utf-8':
            case 'csutf8':
                $php_encoding = 'UTF-8';
                break;
            case 'utf-16':
            case 'csutf16':
                $php_encoding = 'UTF-16';
                break;
            default:
                if ( strpos($html_charset,'sjis') ){
                    $php_encoding = 'SJIS';
                }
                break;
        }

        return $php_encoding;
    }
618520
public function post($key, $type = 'string', $default = null)
    {
        $value = $default;
        if (isset($this->post[$key])) {
            $value = $this->post[$key];
        }
        settype($value, $type);
        return $value;
    }
853767
public function post($uri, $parameters = [], $headers = [])
    {
        if(in_array($uri, $this->urlSignWithPrivateKeys)) {
            if(empty($this->privateKey)) {
                throw new \RuntimeException('the private key is not set yet');
            }

            if(empty($parameters['sign_type'])) {
                $parameters['sign_type'] = 'RSA';
            }
        }

        $response = $this->guzzle->post($uri, [
            'form_params' => $this->prepareForRequest($parameters),
            'headers' => $headers
        ]);

        $data = json_decode($response->getBody(), true);
        if($data['errcode']) {
            throw new \Exception($data['msg'], $data['errcode']);
        }

        if(!$this->verifyResponse($data)) {
            throw new \Exception('响应签名不正确');
        }

        return $this->decodeData($data['data']);
    }
1209079
public function Post($Key = NULL, $Default = NULL) {
      if ($Key === NULL)
         return $this->GetRequestArguments (self::INPUT_POST);
      else
         return $this->GetValueFrom(self::INPUT_POST, $Key, $Default);
   }
896349
static function httpCharset()
    {
        $realCharset =& $GLOBALS['eZTextCodecHTTPCharsetReal'];
        if ( !isset( $realCharset ) )
        {
            $charset = '';
            if ( isset( $GLOBALS['eZTextCodecHTTPCharset'] ) )
                $charset = $GLOBALS['eZTextCodecHTTPCharset'];
            if ( $charset == '' )
            {
                if ( isset( $GLOBALS['eZTextCodecInternalCharsetReal'] ) )
                    $realCharset = $GLOBALS['eZTextCodecInternalCharsetReal'];
                else
                    $realCharset = eZTextCodec::internalCharset();
            }
            else
            {
                $realCharset = eZCharsetInfo::realCharsetCode( $charset );
            }
        }
        return $realCharset;
    }
899523
public function prepend($html, $key = null)
    {
        $this->each(function ($item) use ($html) {
            $item->title = $html.$item->title;
        });

        return $this;
    }
606458
function serialize($charset_encoding='')
		{
			if ($charset_encoding != '')
				$this->content_type = 'application/json; charset=' . $charset_encoding;
			else
				$this->content_type = 'application/json';
			$this->payload = serialize_jsonrpcresp($this, $this->id, $charset_encoding);
			return $this->payload;
		}
1301905
protected function replaceSpecialChars($stringWithSpecialChars)
    {
        if (!is_string($stringWithSpecialChars)) {
            return "";
        }
        $oStr = \OxidEsales\Eshop\Core\Str::getStr();
        $sQuotedPrefix = preg_quote(self::$_sSeparator . self::$_sPrefix, '/');
        $sRegExp = '/[^A-Za-z0-9' . $sQuotedPrefix . '\/]+/';
        $sanitized = $oStr->preg_replace(
            ["/\W*\/\W*/", $sRegExp],
            ["/", self::$_sSeparator],
            $stringWithSpecialChars
        );

        return $sanitized;
    }
797306
public function getBlock($key)
    {
        if (($find = $this->searchBlock($key)) !== null) {
            return $find;
        }

        throw new \Exception(htmlspecialchars("The block $key does not exist."));
    }