You are here

public static function API::method__ip_info in Anti Spam by CleanTalk 8.3

* Wrapper for ip_info API method. * Gets IP country. * *

Parameters

string $data: * @param bool $do_check * * @return array|bool|mixed

File

src/lib/Cleantalk/Common/API.php, line 173

Class

API
CleanTalk API class. Mostly contains wrappers for API methods. Check and send mehods. Compatible with any CMS.

Namespace

Drupal\cleantalk\lib\Cleantalk\Common

Code

public static function method__ip_info($data, $do_check = true) {
  $request = array(
    'method_name' => 'ip_info',
    'data' => $data,
  );
  $result = static::send_request($request);
  $result = $do_check ? static::check_response($result, 'ip_info') : $result;
  return $result;
}