Welcome Guest, Not a member yet? Register   Sign In
CodeIgniter 2.10 doesn't recognize opera mini
#1

[eluser]Unknown[/eluser]
Hi,

Title say it all, $this->agent->is_mobile() returned false (using CodeIgniter 2.10)

$this->agent->agent returned something like this:

Quote: Opera/9.80 (Windows NT 6.1; Opera Mobi/2371; U; en)...
Opera/9.80 (S60; SymbOS; Opera Mobi/SYB-1107071604; U; en)...

This can be easily reproduced this using the Opera Mobile Simulator

Thanks!
#2

[eluser]Unknown[/eluser]
Never mind, I updated my user_agents.php copy and now CI correctly detects opera mini
#3

[eluser]InsiteFX[/eluser]
This also happens with the mime types now and then, we just have to go in and add the new types.
#4

[eluser]bientek[/eluser]
For me, is_mobile() returns false when using my Droid with Opera Mini or the Opera simulator.

Testing on my Droid works fine in Chrome, Firefox, and Android's native browser. On my Droid, the user agent is: "Mozilla/5.0 (Linux; U; Android 4.0.4; en-us; DROID RAZR 4G Build/6.7.2-180_DHD-16_M4-31) AppleWebKit/534.30 (KHTML, like Gecko) Version/4.0 Mobile Safari/534.30"

Site is CI 2.1.3.
#5

[eluser]bientek[/eluser]
From https://github.com/EllisLab/CodeIgniter/issues/683
Adding this to the mobile browsers array in user_agents.php worked:
Code:
'opera mobi' => "Opera Mobi",
Note that CI 2.1.3 lacks this. Was it accidentally removed?
#6

[eluser]Aken[/eluser]
The code was added after 2.1.3 was released.




Theme © iAndrew 2016 - Forum software by © MyBB