Opened 6 years ago

Closed 5 years ago

Last modified 5 years ago

#9892 closed bug (fixed)

Webpositive is detected as a mobile browser by more then a few sites

Reported by: SeanCollins Owned by: pulkomandy
Priority: normal Milestone: R1
Component: Applications/WebPositive Version: R1/Development
Keywords: Cc: diger, ajcsweb@…
Blocked By: Blocking: #10096, #10182, #10485, #10549
Has a Patch: no Platform: x86

Description

Webpositive is reported as a mobile browser constantly, it is getting fairly annoying to use google. Many websites also format pages for webpositive to be mobile oriented.

Not sure what the fix is, but I bet it has to do with the broswer ID tag

Attachments (3)

screenshot1.png (149.1 KB) - added by vidrep 6 years ago.
Yahoo (219.3 KB) - added by vidrep 6 years ago.
Yahoo.2 (663.8 KB) - added by vidrep 6 years ago.

Download all attachments as: .zip

Change History (21)

comment:1 Changed 6 years ago by diver

Cc: diger added

comment:2 Changed 6 years ago by tidux

I suspect it may have to do with capability testing. Mobile sites are often simpler, and a lot of advanced features either don't exist in WebPositive (HTML5 <video> and <audio> support) or are broken (CSS3).

comment:3 Changed 6 years ago by diver

Blocking: 10096 added

comment:4 Changed 6 years ago by umccullough

We took the web+ useragent and plugged it into another browser (Chrome in my case), and found that it does indeed detect as a mobile browser.

After fiddling with things, we found the following useragent seems to work much better:

Mozilla/5.0 (compatible; Haiku R1 x86; en) AppleWebKit/536.10 (KHTML, like Gecko) WebPositive/1.1 Safari/536.10

comment:5 Changed 6 years ago by umccullough

Blocking: 10182 added

comment:6 Changed 6 years ago by umccullough

For reference, the (non-working) user agent we started with was:

Mozilla/5.0 (compatible; U; Haiku x86; en) AppleWebKit/536.10 (KHTML, like Gecko) Haiku/R1 WebPositive/1.1 Safari/536.10

Removing the U; seems to help a bit, and getting rid of the OS version at the end of the string, and moving it into the parenthesized area at the beginning seems to help as well (and that's where most OSes put it) - also you can't put a slash in the OS version or the parser google uses seems to get confused.

Last edited 6 years ago by umccullough (previous) (diff)

comment:7 Changed 6 years ago by waddlesplash

Cc: ajcsweb@… added

comment:8 Changed 6 years ago by pulkomandy

Newer build will use the user agent you provided (with higher WebKit, Web+ and Safari versions, however). But the browser is still misdetected by google.

comment:9 Changed 6 years ago by pulkomandy

Owner: changed from leavengood to pulkomandy
Status: newassigned

comment:10 Changed 6 years ago by pulkomandy

Resolution: fixed
Status: assignedclosed

I'm not sure what happened, but the last run of merges from WebKit seems to have fixed that at least for Google search. Do you have a list of other sites that fail to work?

I think part of the problem is we were reporting an old WebKit/Safari version, and now we report a newer one. But there may be other changes that help as well.

comment:11 Changed 6 years ago by vidrep

Yahoo World News also appears to load as a mobile browser on hrev46651 x86 gcc2.

comment:12 Changed 6 years ago by waddlesplash

@PulkoMandy by "last set of merges" did you mean the ones that happened between the Web+ in recent nightlies and current HWK "rebased" branch"?

Changed 6 years ago by vidrep

Attachment: screenshot1.png added

Changed 6 years ago by vidrep

Attachment: Yahoo added

Changed 6 years ago by vidrep

Attachment: Yahoo.2 added

comment:13 Changed 6 years ago by pulkomandy

Resolution: fixed
Status: closedreopened

Yes, I mean that. It seems Yahoo still doesn't work (just tested here), if you have any other websites showing that problem, please make a list here.

comment:14 Changed 6 years ago by DaaT

Another site that still detects web+ as a mobile browser is ICO. Tested with nightly rev 46649.

comment:15 Changed 6 years ago by pulkomandy

Blocking: 10485 added

comment:16 Changed 6 years ago by anevilyak

Blocking: 10549 added

comment:17 Changed 5 years ago by pulkomandy

Resolution: fixed
Status: reopenedclosed

Should work fine now. Adding "Macintosh" to the user agent avoids most website thinking we are some kind of iOS device...

comment:18 in reply to:  17 Changed 5 years ago by jprostko

Replying to pulkomandy:

Should work fine now. Adding "Macintosh" to the user agent avoids most website thinking we are some kind of iOS device...

Kind of wish we didn't have to do that, but if that's what it takes, I guess that is the way to go for now. Hopefully over time, sites wise up and just look for "Haiku" and do the right thing. I had to adjust some code on my work website to handle Haiku properly after this fix, as it was loading up a Silverlight player (which it loads for Windows and Mac) instead of the HTML5 player. That said, that code needs reworked anyway to not solely rely on user agent, but I admit I was surprised initially when I went to test out HTML5 audio on the site with Web+ and saw the notice to install Silverlight. All ended up well though after I made code changes on my end, as I was able to play audio just fine. :)

Note: See TracTickets for help on using tickets.