简体   繁体   中英

Check Ip is ISP or Company using php

I'm using php whois lookup to fetch details of an ip and I am very much successful in it. But I need to detect whether the ip belongs to an individual or an organization.

For example if I browse my tracking website from home it is my individual ip but if I browse it from my office (my company) it is an organization. The fact is I want to track all "company visitors" visiting my site. I'm not interested in individuals. So I need a way to differentiate between the two. Since if I go for whoislookup of individual ip, it returns the ISP as Organization and for generic organization ip it returns the organization name. So basically I need to detect whether the ip is ISP or Generic Organization.

尝试使用此命令获取与给定 IP 地址对应的 Internet 主机名 ->

string gethostbyaddr ( string $ip_address )

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM