0
votes

When you display user agent (Request.UserAgent) in Firefox on iPhone, it is:

Mozilla/5.0 (iPhone; CPU OS 13_3_1 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) FxiOS/23.0 Mobile/15E148 Safari/605.1.15

It produced an error on page

This page contains the following errors: error on line 306 at column 16: xmlParseEntityRef: no name Below is a rendering of the page up to the first error.

In console:

Uncaught DOMException: Failed to set the 'innerHTML' property on 'Element': The provided markup is invalid XML, and therefore cannot be inserted into an XML document.

The word 'iPhone' is missing between 'CPU OS' compare to Chrome or Edge. If you change it to (by adding 'iPhone' between 'CPU OS' which will become 'CPU iPhone OS'):

Mozilla/5.0 (iPhone; CPU iPhone OS 13_3_1 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) FxiOS/23.0 Mobile/15E148 Safari/605.1.15

No error

Request.UserAgent in Chrome returns:

Mozilla/5.0 (iPhone; CPU iPhone OS 13_3_1 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) CriOS/23.0 Mobile/15E148 Safari/605.1.15

or Request.UserAgent in Edge returns:

Mozilla/5.0 (iPhone; CPU iPhone OS 13_3_1 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) EdgiOS/23.0 Mobile/15E148 Safari/605.1.15

Steps to reproduce: Use user agent 'Mozilla/5.0 (iPhone; CPU OS 13_3_1 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) FxiOS/23.0 Mobile/15E148 Safari/605.1.15' in Chrome.

Any advice how to fix it?

1

1 Answers

0
votes

I know this doesn't answer your question, but I'm glad I stumbled upon your post because I noticed that one of the websites I use was only broken on Firefox for iOS (even Firefox Focus for iOS works, as well as Firefox for iPad). This has got to be the reason why because that's the exact error I'm seeing.

For what it's worth, I've posted on the Firefox Support Forum: https://support.mozilla.org/en-US/questions/1282961

As well as created a ticket on Web Compat: https://webcompat.com/issues/50808

In case those get any feedback, I wanted to make sure you were at least aware.

EDIT: I was instructed by a moderator on the Firefox Support Forum to submit a bug report. You can find this here: https://bugzilla.mozilla.org/show_bug.cgi?id=1625581