codefog / contao-haste

Haste is a collection of tools and classes to ease working with Contao
http://codefog.pl/extension/haste.html
MIT License
42 stars 24 forks source link

{{flag::##raw_data_filled##|nl2br}} breaks when using "|" #203

Open ngdot opened 1 year ago

ngdot commented 1 year ago

If you use {{flag::##raw_data_filled##|nl2br}} in a email html notification for example, it will break if the user writes "|" into the input. It will break too, if the label of the input contains "|". The output stops by the first "|" sign.

System-Log: Unknown insert tag flag " DE " in {{flag::Firma: Verein | DE |nl2br}} on page https://***/ Verein | DE was the user input.

Ofcourse I can remove the "|" characters from the label, but without further ado I can't prevent "|" is used by the user.

Tested with: Contao 4.13.15 Notification Center: 1.7.1 Haste: 5.0.16

fritzmg commented 1 year ago

This is not an issue with Haste, that's a limitation of Insert Tags in general.

// accidentally clicked close