Freemaker配置文件详解


classic_compatible=true              ##如果变量为null,转化为空字符串,比如做比较的时候按照空字符做比较
whitespace_stripping=true          ##去掉多余的空格,非常有用
##模版更新事件,设置为1秒,正式环境设置为3600秒 
#template_update_delay=3600
template_update_delay=1        ##模版更新时间,这里配置是1秒更新一次,正式环境,模版不会改变,可以将这个值设很大,提高效率.就是被这个参数害死了.老是不更新.
locale=zh_CN            ##中国
default_encoding=utf-8   ##编码utf8
url_escaping_charset=utf-8  ##url编码utf8
date_format=yyyy-MM-dd   ##显示日期格式
time_format=HH:mm:Ss       ##显示时间格式
datetime_format=yyyy-MM-dd  ##显示日期格式
number_format=#0.#####  ##数字显示格式hi.
auto_import=/ftl/pony/index.ftl as p,/ftl/spring.ftl as s  表示freemaker这个视图文件会自动引入这个ftl文件,里面定义的就是一些宏,text文本框,form的一些元素

原文地址:https://www.cnblogs.com/zzyrunning/p/4584918.html