Item10595: Prepare template for emptied items
Priority: Enhancement
Current State: Closed
Released In: n/a
Target Release: n/a
In
metacomments.tmpl
the TMPL:Ps are surrounded by newlines, for example:
%TMPL:P{
"comment::photo"
web="%USERSWEB%"
topic="$author"
}%
%IF{"'%ENCODE{"$title" type="entity"}%'!=''" then="<h3>%ENCODE{"$title" type="entity"}%</h3>"}%<!-- -->
Now if
comment::photo
is emptied with
%TMPL:DEF{"comment::photo"}%%TMPL:END%
a standalone newline is created, resulting in an empty paragraph. Better to concatenate:
%TMPL:P{
"comment::photo"
web="%USERSWEB%"
topic="$author"
}%%IF{"'%ENCODE{"$title" type="entity"}%'!=''" then="<h3>%ENCODE{"$title" type="entity"}%</h3>"}%<!-- -->
--
ArthurClemens - 04 Apr 2011
Fix released in 0.91.
--
MichaelDaum - 15 Apr 2011