Identify individual users that are using mobile phones

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
d3chapma
Forum Newbie
Posts: 10
Joined: Thu Nov 16, 2006 10:00 am

Identify individual users that are using mobile phones

Post by d3chapma »

I have a php page where users on mobile phones can fill out a survey. I'm looking for a way that I can get information from the header that will allow me to basically authenticate users so that I know that they are using a mobile phone. The key is that I only want the surveys of users who are using mobile phones to access the page. All other submissions will simply be discarded.

Any thoughts on this?
User avatar
feyd
Neighborhood Spidermoddy
Posts: 31559
Joined: Mon Mar 29, 2004 3:24 pm
Location: Bothell, Washington, USA

Post by feyd »

Many of the request headers, we normally don't have access to. So if these clients send an odd header, PHP may not see it.

Apache supports getallheaders().

Sometimes, they can be identified (although not definitively) through their browser agent string.

get_browser() may be of interest.
Post Reply