Page 1 of 1

PHP and PDAs

Posted: Sat Mar 18, 2006 3:35 am
by Jr
Ok, I'm not sure how to do this (that's why I'm posting obviously) but I was just wondering if PHP has a function that checks for a PDA connecting to a page instead of a PC or just how I would do that. I have a lot of JavaScript on one of my sites and it doesn't work on my PDA so I want to make a "PDA spacific" site that just loads when a PDA connects to my site. If someone could post up and let me know how I could do this I would greatly appriciate it as always.

Thanks,
Jr-

Posted: Sat Mar 18, 2006 6:31 am
by Chris Corbyn
Just check $_SERVER['USER_AGENT'].

It's not perfect and can be spoofed but it should help with pretty much all standard PDA setups.

Posted: Sat Mar 18, 2006 9:30 am
by feyd
get_browser() and/or the associated data file could be of help here.