TeXhackse / LaTeX-ZUGFeRD

LaTeX packages to create ZUGFeRD/Faktur-X invoices
33 stars 8 forks source link

escaping special chars for XML (&<>"') #9

Open SaculRennorb opened 1 month ago

SaculRennorb commented 1 month ago

I initially encountered this issue while using buyer information that contained a \& in the name, which produces invalid xml if left unescaped.

I don't expect the packege to do the escaping for me, seeing as this might be quite expensive to always do on all fields, but some remarks should be added into the documentation about this imo.

TeXhackse commented 1 month ago

Thanks for the suggestion. It's actually not that expensive as the mechanism is already there and could be extended. But I will think about it. Generally I'd not do replacements like this by default, as that's a task a personal wrapper package which depends on your input should resolve.

TeXhackse commented 1 month ago

I decided to do this as an enhancement for the macros to set variables. But it will never be enabled by default, therefore this is not an urgent enhancement, but I will keep this issue open as a reminder. It's mentioned in the docs.