function smart_ip_get_count in Smart IP 7.2
Same name and namespace in other branches
- 6.2 smart_ip.module \smart_ip_get_count()
- 6 smart_ip.module \smart_ip_get_count()
- 7 smart_ip.module \smart_ip_get_count()
Get the total count of IP ranges in database
1 call to smart_ip_get_count()
- _smart_ip_database_update_submit in includes/
smart_ip.admin.inc - Submit handler to update the Smart IP database.
File
- ./
smart_ip.module, line 998 - Determines country, geo location (longitude/latitude), region, city and postal code of the user, based on IP address
Code
function smart_ip_get_count() {
smart_ip_check_fix_local_db();
$sql = 'SELECT COUNT(*) FROM {smart_ip}';
$count = db_query($sql);
return (int) $count
->fetchField(0);
}