varnishcache / varnish-devicedetect

VCL based device detection for Varnish Cache.
Other
300 stars 88 forks source link

Tablet PC in varnish-device detect #19

Closed pongacm closed 9 years ago

pongacm commented 9 years ago

I compared varnish-device detect method with UA Parser and I noticed that varnish method not detected Tablet PC devices as a mobile (where regexp_like(useragent, '(Tablet._PC|PC._Tablet)', 'i')).

I uploaded sample of user agents on the gist: https://gist.github.com/pongacm/b7775bebf2b26c09e1f8

Wikipedia says that tablet PC is a tablet: http://en.wikipedia.org/wiki/Microsoft_Tablet_PC

I'm analyst so I can't prepare pull request. Is any chance to improve varnish-device detect by somone with you?

serbanghita commented 9 years ago

@pongacm from what I know Tablet PC can also be confused with Windows Media Center, I know I used to have Windows Media Center Edition and on my desktop IE used to contain Tablet PC. From my experience with Mobile_Detect the only valid combination would be ARM.*Tablet PC or a variant.

lkarsten commented 9 years ago

There also seem to be a "Touch" in the tablet's user-agent, so I matched on both of those.

With some luck this won't be too far off.