How do I find the network type(EDGE, UTMS, HSPDA etc) of user accessing my site in php


Recommended Answers

All 4 Replies

the only thing you can do, I think is look up in by IP address, but at first you should have a huge IP-Type database to support you.

Member Avatar

I agree, the only way I can think of is to check the user's IP against a database. BUT, IPs can be spoofed - even the $_SERVER['REMOTE_ADDR'] is not to be trusted. However, as you seem to be using it to collect data or to deliver custom data, it may not be a huge concern.

There may be a few APIs out there that allow you to check the network type without having to host your own copy of a DB - which would probabkly be better as otherwise, you'd have to keep updating said DB on a very regular basis. I'm not aware of a free/limited-use API though. You'll probably have to pay for it, if you can find one.

Ok thanks. You also try my luck

Why do you want to know?
Or do you want to know the connection speed?

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, learning, and sharing knowledge.