<bean class="org.springframework.web.servlet.view.freemarker.FreeMarkerConfigurer">
<property name="templateLoaderpaths" value="/WebContent/jsp/"></property>
<property name="defaultEncoding" value="utf-8"></property>
<property name="freemarkerSettings">
<props>
<prop key="locale">zh_CN</prop>
</props>
</property>
</bean>
<bean class="org.springframework.web.servlet.view.freemarker.FreeMarkerViewResolver">
<property name="suffix" value=".*"></property>
<property name="contentType" value="text/html;charset=utf-8"></property>
<property name="requestContextAttributes" value="request" />
<property name="exposeRequestAttributes" value="true" />
<property name="exposeSessionAttributes" value="true" />
</bean>
org.springframework.beans.NotWritablePropertyException: Invalid property 'templateLoaderpaths' of bean class [org.springframework.web.servlet.view.freemarker.FreeMarkerConfigurer]: Bean property 'templateLoaderpaths' is not writable or has an invalid setter method. Did you mean 'templateLoaderPath', or 'templateLoaderPaths'?at org.springframework.beans.BeanWrapperImpl.setPropertyValue(BeanWrapperImpl.java:1064)
at org.springframework.beans.BeanWrapperImpl.setPropertyValue(BeanWrapperImpl.java:924)
at org.springframework.beans.AbstractPropertyAccessor.setPropertyValues(AbstractPropertyAccessor.java:76)
at org.springframework.beans.AbstractPropertyAccessor.setPropertyValues(AbstractPropertyAccessor.java:58)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.applyPropertyValues(AbstractAutowireCapableBeanFactory.java:1393)
... 31 more
templateLoaderpaths
这个bean的名称不对,改成这个试试templateLoaderPaths
版权声明:本文内容由阿里云实名注册用户自发贡献,版权归原作者所有,阿里云开发者社区不拥有其著作权,亦不承担相应法律责任。具体规则请查看《阿里云开发者社区用户服务协议》和《阿里云开发者社区知识产权保护指引》。如果您发现本社区中有涉嫌抄袭的内容,填写侵权投诉表单进行举报,一经查实,本社区将立刻删除涉嫌侵权内容。