format; } if(!$vars['max-results']){ $vars['max-results'] = $this->max_results; } if(!$vars['format']){ $vars['format'] = 5; } $request =""; foreach($vars as $var => $val){ if($request!="") $request.="&"; $request.=$var."=".rawurlencode($val); } $search_url = $this->url_api."?".$request; $curl = new Curl(); $json = $curl->get($search_url); return json_decode($json); } }