Subversion Repositories SmartDukaan

Rev

Rev 17885 | Rev 18111 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 17885 Rev 17897
Line 353... Line 353...
353
		rtrim($fields_string, '&');
353
		rtrim($fields_string, '&');
354
		//set the url, number of POST vars, POST data
354
		//set the url, number of POST vars, POST data
355
		curl_setopt($ch,CURLOPT_URL, $url);
355
		curl_setopt($ch,CURLOPT_URL, $url);
356
		curl_setopt($ch,CURLOPT_POST, count($fields));
356
		curl_setopt($ch,CURLOPT_POST, count($fields));
357
		curl_setopt($ch,CURLOPT_POSTFIELDS, $fields_string);
357
		curl_setopt($ch,CURLOPT_POSTFIELDS, $fields_string);
358
		curl_setopt($ch,CURLOPT_HTTPHEADER, array('Content-Type: multpipart/form-data'));
-
 
359
		$result = curl_exec($ch);
358
		$result = curl_exec($ch);
360
		$this->log("[response] ".print_r($result,1),'api');
359
		$this->log("[response] ".print_r($result,1),'api');
361
		//close connection
360
		//close connection
362
		curl_close($ch);
361
		curl_close($ch);
363
		switch($format){
362
		switch($format){