FreeMarker Current Date Comparison

前端 未结 4 2529

Is it possible to do date comparisons against the current date in a freemarker template without passing the current date into the template?

4条回答
  •  囚心锁ツ
    2021-02-20 13:47

    NO

    Freemarker is a templating library, there isn't a today variable.

    But you can pass a new Date() Java Object to the template.

提交回复
热议问题