标签:
1、spring-servlet.xml配置如下:
<bean id="viewResolver" class="com.vinuxpay.framework.core.web.springmvc.VinuxpayVelocityViewResolver">
<property name="prefix" value="/" />
<property name="suffix" value=".vm" />
<property name="exposeSpringMacroHelpers" value="true" />
<property name="exposeSessionAttributes" value="true" />
<property name="exposeRequestAttributes" value="true" />
<property name="requestContextAttribute" value="rc" />
<property name="contentType" value="text/html;charset=UTF-8" />
</bean>
2、velocity页面获取
$session.getAttribute("CHERRYUSER").LOGIN_NAME
标签:
原文地址:http://my.oschina.net/u/734885/blog/499961