Hi.
I want to have a simple list of song-titles on my page. But the titles are in German and can contain umlauts and special characters. I managed to convert the titles in the format of the PDF-names:
{{titel | replace ({"ä":"ae"})
     | replace ({"ä":"ae"})
      | replace ({"ö":"oe"})
      | replace ({"ü":"ue"})
      | replace ({"Ä":"Äe"})
      | replace ({"Ö":"Oe"})
      | replace ({"Ü":"Üe"})
      | title
      | slug('')
}}
I put that into a header-Stack and I can see the correct conversion:
In my CSV "title" is for example "Wir machen ein Späßchen".
This converts to "WirMachenEinSpaesschen"
The PDF of that song is "WirMachenEinSpaesschen.pdf"
I thought, that I can put the header-stack into a link-container-stack whith the following link:
https://www.juergenklotz.de/resources/lieder/{{ titel
| replace ({"ä":"ae"})
| replace ({"ä":"ae"})
| replace ({"ö":"oe"})
| replace ({"ü":"ue"})
| replace ({"Ä":"Äe"})
| replace ({"Ö":"Oe"})
| replace ({"Ü":"Üe"})
| title
| slug('')
}}.pdf
But that leads to a twig error in preview.
Make link to PDFs out of German song-titles
8 replies