发送post请求
@param string $url
@param string $param
@return bool|mixed
977409
public static  function parsePostJson($url = '', $param = '')
    {
        if (empty($url) || empty($param)) {
            return false;
        }
        $postUrl = $url;
        $curlPost = $param;
        $ch = curl_init(); //初始化curl
        curl_setopt($ch, CURLOPT_URL, $postUrl); //抓取指定网页
        curl_setopt($ch, CURLOPT_HEADER, 0); //设置header
        curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1); //要求结果为字符串且输出到屏幕上
        curl_setopt($ch, CURLOPT_POST, 1); //post提交方式
        curl_setopt($ch, CURLOPT_POSTFIELDS, $curlPost);
        $data = curl_exec($ch); //运行curl
        curl_close($ch);
        return json_decode($data, TRUE);
    }
782631
public function get($url, $params = null) {
    $this->params = $params;
    $this->method = 'GET';
    $this->url = $url;

    return $this->request();
  }
150866
public function post($url, $params = array(), $options = array())
    {
        return $this->request($url, self::POST, $params, $options);
    }
337309
public function getParam($param = null)
    {
        if (null === $param) {
            return $this->_params;
        }

        return isset($this->_params[$param]) ? $this->_params[$param] : null;
    }
821921
private String doPostByUrl(String uri, String param) throws IOException {
        HttpURLConnection connection;
        URL url = new URL(uri);

        connection = (HttpURLConnection)url.openConnection();           // 新建连接实例
        connection.setConnectTimeout(Constant.DEFAULT_CONN_TIMEOUT);    // 设置连接超时时间，单位毫秒
        connection.setReadTimeout(Constant.DEFAULT_READ_TIMEOUT);       // 设置读取数据超时时间，单位毫秒
        connection.setDoInput(true);                                    // 是否打开输出流 true|false
        connection.setDoOutput(true);                                   // 是否打开输入流true|false
        connection.setRequestMethod(Constant.RequestMethodPost);        // 提交方法POST|GET
        connection.setUseCaches(false);                                 // 是否缓存true|false
        connection.connect();                                           // 打开连接端口

         out = new (connection.getOutputStream());
        out.writeBytes(param);
        out.flush();
        out.close();

        BufferedReader reader
                = new BufferedReader(
                        new InputStreamReader(connection.getInputStream(),
                                                Constant.DEFAULT_CHARSET));
        StringBuilder buffer = new StringBuilder();
        String line;
        while ((line = reader.readLine())!= null) {
            buffer.append(line);
        }

        // 关闭连接
        reader.close();
        connection.disconnect();

        return buffer.toString();
    }
1129567
public function getParam(string $param)
    {
        if (! empty($this->match['params'][$param])) {
            return $this->match['params'][$param];
        }
    }
686020
private function post($url, array $query = array())
    {
        return $this->browser->post($url, array(), $this->prepareQueryString($query));
    }
1367644
public function post($url, $body)
    {
        $this->addHeader('Content-Type', $this->getContentType());

        if (!is_string($body)) {
            $body = json_encode($body);
        }

        $this->initializeRequest();

        curl_setopt($this->curl, CURLOPT_CUSTOMREQUEST, 'POST');
        curl_setopt($this->curl, CURLOPT_URL, $url);
        curl_setopt($this->curl, CURLOPT_POST, true);
        curl_setopt($this->curl, CURLOPT_PUT, false);
        curl_setopt($this->curl, CURLOPT_HTTPGET, false);
        curl_setopt($this->curl, CURLOPT_POSTFIELDS, $body);
        curl_exec($this->curl);

        return $this->handleResponse();
    }
589297
public static void post(URL url, String params) throws IOException {
        URLConnection conn = url.openConnection();
        if (conn instanceof HttpURLConnection) {
            ((HttpURLConnection) conn).setRequestMethod("POST");
            conn.setRequestProperty("Content-Type" , "application/json");
        }
        OutputStreamWriter writer = null;
        try {
            conn.setDoOutput(true);
            writer = new OutputStreamWriter(conn.getOutputStream(),
                    Charset.forName("UTF-8"));
            // write parameters
            writer.write(params);
            writer.flush();
        } finally {
            if (writer != null) {
                writer.close();
            }
        }
    }
1173181
public function get($url, array $params = [])
    {
       $queryString = '?' . http_build_query($params);

       $url = $url . $queryString;

       $request = new Request(
            $url,
            'GET'
        );

        return $this->send($request);
    }
362734
public function create_url($url , $param){

        $url .= "?";
        $i = 0;
        foreach ($param as $k=>$v){
            $i++;
            if ($i == count($param)){
                $url .= $k . '=' . $v;
            }else{
                $url .= $k . '=' . $v . '&';
            }

        }

        return $url;
    }
94947
public static function addParameter($url, $params)
    {
        if (!$url) {
            return $url;
        }
        if ($params) {
            if (is_array($params)) {
                $newParams = [];
                foreach ($params as $key => $item) {
                    $newParams[] = $key . '=' . $item;
                }
                $params = join('&', $newParams);
            }
            return $url . (strstr($url, '?') ? '&' : '?') . $params;
        }
        return $url;
    }
280695
protected function getParam($param)
    {
        $params = $this->getParams();
        if (! isset($params[$param])) {
            return false;
        }
        return $params[$param];
    }
926124
public function request($url)
    {
        $params = $this->parameters;
        $data = $params->getPostList();
        $data['signature'] = $this->getSignature($data);
        $data['key'] = $params->getAuth('key');

        $url = $params->getAuth('apiHost') . $params->getAuth('apiVersion') .'/'. $url .'.'. $params->getAuth('apiFormat');
        $data = json_encode($data);

        $ch = curl_init();
        curl_setopt($ch, CURLOPT_URL, $url);
        curl_setopt($ch, CURLOPT_POST, true);
        curl_setopt($ch, CURLOPT_POSTFIELDS, $data);
        curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);

        if ($params->getAuth('disableSSLChecks')) {
            curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, false);
            curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false);
        }

        curl_setopt($ch, CURLOPT_HTTPHEADER, array(
            'Content-Length: ' . mb_strlen($data),
            'Content-Type: application/json'
        ));

        if ($params->hasProxy()) {
            curl_setopt($ch, CURLOPT_PROXY, $params->getProxy());
        }

        $result = curl_exec($ch);
        $info = curl_getinfo($ch);
        $error = curl_error($ch);
        $errno = curl_errno($ch);

        curl_close($ch);

        if ($result === false && !empty($error)) {
            throw new NetworkException($error, $errno);
        }

        return $this->parseResponse($result, $info);
    }
219535
public function put($url, array $params = [])
    {
        return $this->request($this->createUrl($url), self::METHOD_PUT, $params);
    }
401798
public function post($url, $params = array(), $headers = array(), $options = array(), $fopen = false)
    {
        return $this->request('POST', $url, $params, $headers, $options, $fopen);
    }
1079526
public function post($url, $data = [])
    {
        $this->setOpt(CURLOPT_URL, $this->_buildURL($url));
        $this->setOpt(CURLOPT_POST, true);
        $this->setOpt(CURLOPT_POSTFIELDS, $this->_postfields($data));

        return $this->exec();
    }