Bug in Safari 17.0: double quotes appear within text of websites

Since upgrade to Safari 17.0 (macOS 14.0), double quotation marks appear in rendered html text. This is a bug in Safari rendering.

It seems that carriage returns within the html code of the text (which are usually ignored in rendering) are translated into double quotation ".

This bug did not occur for versions < 17.0.


See images attached.


First screenshot: HTML code containing carriage return, see '... kreiert. \cr Das Besondere ...'

Second screenshot: This is rendered as '... kreiert."Das Besondere ...'


The problem is the " appearing as a character rendering instead of ignoring \cr.


Screenshots are taken from: https://www.wellness-heaven.de/wellnesshotel/interalpen/testbericht-kulinarik/



iMac 27″, macOS 10.12

Posted on Oct 4, 2023 9:11 AM

Reply
Question marked as Top-ranking reply

Posted on Oct 6, 2023 2:49 AM

Note I edited my website above already to fix the problem.

Still, the bug in Safari persists in general.


I boiled down the bug in Safari to the following "offending" html code with fonts:


<html>
<head>
<style>
@font-face {
    font-family:'MyriadSetPro-Text';
    src: url('https://www.wellness-heaven.de/css/fonts/MyriadSetPro-Text_gdi.eot');
    src: url('https://www.wellness-heaven.de/css/fonts/MyriadSetPro-Text_gdi.eot?#iefix') format('embedded-opentype'),
        url('https://www.wellness-heaven.de/css/fonts/MyriadSetPro-Text_gdi.woff') format('woff'),
        url('https://www.wellness-heaven.de/css/fonts/MyriadSetPro-Text_gdi.ttf') format('truetype'),
        url('https://www.wellness-heaven.de/css/fonts/MyriadSetPro-Text_gdi.svg#MyriadSetPro-Text') format('svg');
    font-weight: 400;
    font-style: normal;
    font-stretch: normal;
    font-display: swap;
    unicode-range: U+0020-2212;
}
</style>
</head>
<body>
<div style="font-family:'MyriadSetPro-Text';">
First line
Second line
</div>
</body> 
</html>


This seems to be an universal, major bug in Safari 17.0.

The problem in Safari seems to be the usage of .woff or .ttf fonts in combination with "unicode-range".


If I delete "unicode-range", the problem goes away. Also, if I only use the .svg font, no problem.


So I just deleted unicode-range on my website (see first post).

Similar questions

2 replies
Question marked as Top-ranking reply

Oct 6, 2023 2:49 AM in response to tasssilo

Note I edited my website above already to fix the problem.

Still, the bug in Safari persists in general.


I boiled down the bug in Safari to the following "offending" html code with fonts:


<html>
<head>
<style>
@font-face {
    font-family:'MyriadSetPro-Text';
    src: url('https://www.wellness-heaven.de/css/fonts/MyriadSetPro-Text_gdi.eot');
    src: url('https://www.wellness-heaven.de/css/fonts/MyriadSetPro-Text_gdi.eot?#iefix') format('embedded-opentype'),
        url('https://www.wellness-heaven.de/css/fonts/MyriadSetPro-Text_gdi.woff') format('woff'),
        url('https://www.wellness-heaven.de/css/fonts/MyriadSetPro-Text_gdi.ttf') format('truetype'),
        url('https://www.wellness-heaven.de/css/fonts/MyriadSetPro-Text_gdi.svg#MyriadSetPro-Text') format('svg');
    font-weight: 400;
    font-style: normal;
    font-stretch: normal;
    font-display: swap;
    unicode-range: U+0020-2212;
}
</style>
</head>
<body>
<div style="font-family:'MyriadSetPro-Text';">
First line
Second line
</div>
</body> 
</html>


This seems to be an universal, major bug in Safari 17.0.

The problem in Safari seems to be the usage of .woff or .ttf fonts in combination with "unicode-range".


If I delete "unicode-range", the problem goes away. Also, if I only use the .svg font, no problem.


So I just deleted unicode-range on my website (see first post).

This thread has been closed by the system or the community team. You may vote for any posts you find helpful, or search the Community for additional answers.

Bug in Safari 17.0: double quotes appear within text of websites

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple Account.