True. That's what I meant by glueing both proposals at some time but not for 1.5, probably for a future release. The helper should stand primarily for the request Context and it should provide detecting and/or switching based on other request parameters/environment as well. We don't actually need 2 or more components for this and it has to be part of the Controller_Action_Helpers. That's what I think. Any views on this for a future release!?
On 1/31/08, Matthew Weier O'Phinney <[EMAIL PROTECTED]> wrote: > > -- Inash Zubair <[EMAIL PROTECTED]> wrote > (on Thursday, 31 January 2008, 04:55 PM +0500): > > Sorry I missed sending this previously to the list. Here it is now. > > > > I'm assuming the purpose of this component is to detect the type of > client and > > customize the output to fit it's capabilities. There is a similar > component > > already in the incubator for version 1.5 and probably that will be > rolled out > > with the PR version of 1.5 that is Zend_Controller_Action_Helper > > _ContextSwitch which does something similar. > > > > Matthew: Is there a possibility both these proposals could be glued!? > The > > purpose is similar as far as I know but how the context is determined is > > different. > > ContextSwitch currently only looks for a given parameter in the request. > However, once we have UserAgent detection, I can write support for that > into ContextSwitch. UserAgent support will *not* happen by 1.5, however. > > > > On 1/31/08, Matthew Weier O'Phinney <[EMAIL PROTECTED]> wrote: > > > > -- Simone Carletti <[EMAIL PROTECTED]> wrote > > (on Wednesday, 30 January 2008, 09:52 PM +0100): > > > a friend of mine created the best ASP class for user agent > sniffing. > > > It's a long time project, started more than 5 years ago. It's > called > > WBStat. > > > http://www.useragents.org/develop-wbstat.asp > > > > > > 4 years ago I created a tracking tool and this class was part of > the > > > application core. > > > We made a kind of partnership: I was in charge of providing the > class > > tons of > > > new user agents and my friend was in charge of updating the > database. > > > This is the result: http://www.useragents.org/ > > > Probably on of the huge useragent database, daily updated with > > > > > > * 153 browsers, > > > * 221 robots, > > > * 89 operating systems > > > * 2045 unique user-agent string (the real database is more than > 400k user > > > agents) > > > > > > Have a look at what the class can do just from an user agent! > > > http://www.useragents.org/develop-wbstat.asp?w=demo > > > > > > I always promised to myself (and to him!) to create a PHP porting > of this > > > excellent tool for ZF. > > > You should definitely have a look at the class. > > > > > > It is Italian based but the code is international! ;) > > > The class is just the core, client definitions are stored in 3 > external > > XML > > > files that can be easily adapted to ZF needs. > > > > > > You should definitely have a look at this wonderful piece of code. > :) > > > > Before he does, what is the license? Depending on the license, we > may > > not be able to accept such a port... > > > > > > > On Wed, Jan 30, 2008 at 8:26 PM, Christer Edvartsen < > [EMAIL PROTECTED]> > > > wrote: > > > > > > I have created a page in the wiki that will hold the proposal > for a > > > Zend_UserAgent component. The proposal does not hold that much > > > information yet, but I will add some more as soon as I get > some > > feedback > > > from you guys. It's located at > > > http://framework.zend.com/wiki/display/ZFPROP/ > > > Zend_UserAgent+-+Christer+Edvartsen > > > > > > The component is supposed to be used to classify user agents > into > > some > > > predefined categories. I suggest the following categories: > > > > > > * Browser > > > * RSS Reader > > > * Mobile Device > > > * Robot > > > > > > A Zend_Controller_Action helper could also be made by using > this > > > component but I guess something like this could live outside > of a > > > typical MVC application so I suggest it as a separate > component. > > > > > > There are several user agent databases out there, and the one > I was > > > thinking about using is http://www.user-agents.org/ which has > an > > > extensive list of user agent strings. One problem is that the > > database > > > does not have the "Mobile device" category. The list is huge > though > > > (2500+ user agents) and I don't think it would be necessary to > use > > > _every_ user agent string in that database. > > > > > > Does anyone have any ideas of how to decide of what list we > could use > > > for something like this? The component will be made in such a > manner > > > that developers can add their own list/database if they think > the one > > we > > > provide is not sufficient. > > > > > > The component could also be extended to fetch some more > detalied > > > information about mobile devices using WURFL > > > (http://wurfl.sourceforge.net/). > > > > > > Any comments? > > > > > > > > > -- > > > Christer Edvartsen > > > [EMAIL PROTECTED] > > > http://cogo.wordpress.com/ > > > > > > > > > > -- > > Matthew Weier O'Phinney > > PHP Developer | [EMAIL PROTECTED] > > Zend - The PHP Company | http://www.zend.com/ > > > > > > > > > > -- > > Inash Zubair > > -- > Matthew Weier O'Phinney > PHP Developer | [EMAIL PROTECTED] > Zend - The PHP Company | http://www.zend.com/ > -- Inash Zubair
