Upper formats as html-specialchars
When using |upper on a variable, "DÆK OG FÆLGE" is showen as "DÆK OG FÆLGE"
When not using filers, or using capatilize it works fine.
using twig/twig (v1.16.2)
The issue seems to be that you apply the upper filter after escaping the HTML, which makes the HTML entity uppercased, thus breaking it (or maybe it gets escaped a second time)
@scansec Can you confirm @stof intuition?
@fabpot , no, due to that it works using the filter capatilize, but not when using the filter uppercase.
Your original string is dæk og fælge and not dæk og fælge as you may see in your browser, because your browser interprets the æ symbol to æ. The uppercase value for æ is Æ and not Æ, so if you're applying uppercase filter on the whole string, you're breaking those HTML entities.
Capitalize filter only puts the first string's character to uppercase, so entities are not affected and you do not see any issue.
Closing as there is no feedback. @scansec Feel free to reopen with a reproducible test case if you still have the problem. Thanks.
Here's your test case:
https://twigfiddle.com/93xg4u
@dommel You need to apply the raw filter after the upper filter: https://twigfiddle.com/93xg4u/2
I see @xabbuh, thanks!