[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[jfw] Re: The future of Joomla\Application\Client



I Agree, I was looking at this after helping to improve browser detection for a template framework. There is a lot that is not detected (edge for example), and somethings are attributed to the wrong rendering engine (chrome) because at some version the rendering engine in the browser changed. I had a hard time wrapping my head around the logic for how the WebClient browser detection worked or why it's setting the browser as a numeric constant. (basically I'm not sure how the consuming packages are using this library)

I think there is definitely interest in the WebClient browser detection being a separate package. 

There are also additional options for detection, currently we are using the $_SERVER['HTTP_USER_AGENT'] constant, and then using custom parsing of the user_agent string. We could possibly pull in the browscap.ini and use get_browser() to have a better object to work with. Although I'm not sure if pointing to a "custom" browscap.ini during runtime with ini_set('browscap', '[thebrowscap.ini file location]'); will give us the necessary ability to use get_browser()

The alternative would be pulling in a fully built out browscap library https://github.com/browscap/browscap-php (a userland replacement for PHP's native get_browser() function) 


--
Framework source code: https://github.com/joomla-framework
Visit http://developer.joomla.org for more information about developing with Joomla!
---
You received this message because you are subscribed to the Google Groups "Joomla! Framework Development" group.
To unsubscribe from this group and stop receiving emails from it, send an email to joomla-dev-framework+unsubscribe AT googlegroups.com.
Visit this group at https://groups.google.com/group/joomla-dev-framework.