Add define to optionally enable escape-on-output
This adjusts the smarty class such that if you have the define below
escape-on-output is enabled
This PR + fixing the use of isset in the template layer are the pre-requisites for
turning escape on output on and off. Keeping this part in an unmerged branch is
tricky as the templates need to be recompiled when you switch to a branch
which does not have this function
I envisage us starting to use this define in our dev environments fairly soon
as it's working well locally for me on
https://github.com/civicrm/civicrm-core/pull/21935