CodeIgniter Forums

Full Version: Custom User Agent
You're currently viewing a stripped down version of our content. View the full version with proper formatting.

El Forum

[eluser]heliguy[/eluser]
I'm trying to be able to detect the Sprint HTC Evo phone but am having troubles trying to add it to the user agent file in CI.

This is the user agent string from the device:
Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10_6_5; en-us) AppleWebKit/533.19.4 (KHTML, like Gecko) Version/5.0.3 Safari/533.19.4

Any ideas?

El Forum

[eluser]umefarooq[/eluser]
yes you can add custom user agent check in application>config>user_agent.php file will help you to solve your problem

El Forum

[eluser]heliguy[/eluser]
I've been attempting to modify the user_agent.php file in the config folder, but have had no luck. I didn't know if anyone here could help me with what to actually put in the user_agent.php file.