Translate the last string. Output $var1,...,$varn replaced into the %s positions in the translated string.
- <? if($variable) { ?>
- Output/execute the text until "<? } ?>" only if $variable is boolean and true.
+ Output/execute the text until "<? } ?>" only if $variable not null or Boolean.FALSE.
- <? foreach($variable) { ?>
If $variable is an "IterableDataset"
@Override
public void output(PrintWriter out, Language l, Map<String, Object> vars) {
Object o = vars.get(variable);
- if (o instanceof Boolean && o == Boolean.TRUE) {
+ if (!(o == Boolean.FALSE || o == null)) {
body.output(out, l, vars);
}
}