function ip2country_get_count in IP-based Determination of a Visitor's Country 8
Same name and namespace in other branches
- 6 ip2country.module \ip2country_get_count()
- 7 ip2country.module \ip2country_get_count()
Gets the total count of IP ranges in database.
Return value
int Integer count of the number of rows in the ip2country table.
Deprecated
in ip2country:8.x-1.9 and is removed from ip2country:8.x-2.0. Use the ip2country.manager service instead. For example, \Drupal::service('ip2country.manager')->getRowCount().
See also
https://www.drupal.org/node/3076484
File
- ./
ip2country.module, line 168 - Determination of user's Country based on IP.
Code
function ip2country_get_count() {
@trigger_error("ip2country_get_count() is deprecated in ip2country:8.x-1.9 and is removed from ip2country:8.x-2.0. Use \\Drupal::service('ip2country.manager')->getRowCount() instead. See https://www.drupal.org/node/3076484", E_USER_DEPRECATED);
return \Drupal::service('ip2country.manager')
->getRowCount();
}