combine_query() static public method

合并URL字串,parse_query的反向函数
static public combine_query ( $urls ) : string
$urls
return string
Example #1
0
 function call($param, $post = null)
 {
     foreach ($param as &$m) {
         if (is_array($m) or is_object($m)) {
             $m = serialize($m);
         }
     }
     $url = $this->server_url . \Swoole\Tool::combine_query($param);
     if ($post === null) {
         $res = $this->http->get($url);
     } else {
         $res = $this->http->post($url, $post);
     }
     if ($this->debug) {
         echo $url, BL, $res;
     }
     return json_decode($res);
 }