【问题标题】:Thymeleaf: Exception processing template "index": Template mode "LEGACYHTML5 " has not been configuredThymeleaf:异常处理模板“索引”:模板模式“LEGACYHTML5”尚未配置
【发布时间】:2016-04-19 15:06:30
【问题描述】:

我正在使用 SpringBoot + Thymeleaf,我正在尝试将模式切换到 LEGACYHTML。我在application.properties 中添加了以下行:

spring.thymeleaf.mode=LEGACYHTML5 

我收到以下错误:

Exception processing template "index": Template mode "LEGACYHTML5 " has not been configured

我希望有人可以帮助我:l。 感谢您的宝贵时间

【问题讨论】:

  • Thymeleaf 的哪个版本?

标签: spring spring-boot thymeleaf


【解决方案1】:

我终于解决了。我真的不知道发生了什么,但我删除了我的 aplication.properties 行,我再次写了它并且它起作用了。 感谢您编辑我的问题,呵呵,我对此有点陌生

【讨论】:

    【解决方案2】:

    我也有同样的问题。 一定是“LEGACYHTML5”后面的空格字符造成的。 删除配置文件中的空格字符解决了问题。

    【讨论】:

      猜你喜欢
      • 2019-10-11
      • 1970-01-01
      • 1970-01-01
      • 2018-12-28
      • 2019-04-05
      • 1970-01-01
      • 1970-01-01
      • 2017-03-08
      • 1970-01-01
      相关资源
      最近更新 更多