Strange display issues in heading tags
jdsimcoe opened this issue · comments
Recently I have encountered two local Craft sites running in Laravel Valet that have developed a strange case of
characters inserted after every character:
In this case, it was inserted in an <h2>
class. Any ideas on why this might be happening? Nothing has changed with my configuration or output.
Here is the snippet of code that is controlling this output:
<h2 class="font-weight-bold">
{{ block.heading|nl2br|typogrify }}
</h2>
For me, this issue started to occur when enabling PHP 7.3 and was fixed again when switching back to PHP 7.2
Seems to be related to craftcms/cms#4239
Wow, thanks @msiemens that's helpful to know it's not just me. Is there a way to fix this?
For me a quick and dirty workaround was to comment out the en_US.utf8
line from vendor/craftcms/craft/bootstrap/web.php
(line 40 for me):
And clear the template caches after this change, of course 🙃
Thanks, @msiemens. Not sure how that would work on a site on Laravel Forge where deploys or craft/cms
updates could wipe that out. Do you know if a long-term change is in the works?
I've reported the issue on craftcms/cms but am waiting for an answer too
I'm seeing this again on Craft 3.4.9 & PHP 7.3.13.
Having this issue come up on a recent project: Craft CMS 3.5.18 and PHP 7.3.22 (Using Valet)
I just got things working by setting set_space_collapse
to false
in my typogrify.php
config file.
Thx @jsunsawyer