Re: Remove get_browser() from core
| From: | Martin Keckeis | Date: | Thu, 03 Dec 2015 16:21:36 +0000 |
| Subject: | Re: Remove get_browser() from core | ||
| References: | 1 2 3 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-89581@lists.php.net to get a copy of this message | ||
2015-12-03 14:38 GMT+01:00 Pierre Joye <pierre.php@gmail.com>:
>
> On Dec 3, 2015 8:32 PM, "Zeev Suraski" <zeev@zend.com> wrote:
> >
> >
> > > On 2 בדצמ׳ 2015, at 9:52, Martin Keckeis <martin.keckeis1@gmail.com>
> wrote:
> > >
> > > Hello together,
> > >
> > > i think it's time to deprecate the function get_browser().
> > >
> >
> > +1. Would be nice if we could point to a recommended alternative in the
> deprecation message.
>
> +1 too.
> Hard to do it in the error message but there are plenty of tools doing a
> far better jobs using log analysis (for the stats).
>
> Cheers,
> Pierre
>
A message would really be good.
But get_browser() is a bit special, since it returns the "browser
capabilities" which only this type of parser can do.
So the "dropin" replacement would be
https://github.com/browscap/browscap-php
I will soon publish a new check with >1000k user agents analyzed by 9
different parsers out there...will notice you if it's done.
Best regards
Martin