【SSH】struts2中的struts.xml相关的一些基本常量配置

请求后缀

<!-- 所有匹配*.action的请求都由struts2处理 -->
<constant name="struts.action.extension" value="action" />

是否启用开发模式

<!-- 是否启用开发模式 -->
<constant name="struts.devMode" value="true" />

修改struts.xml后是否需要重新加载`

<!-- struts配置文件改动后,是否重新加载 -->
<constant name="struts.configuration.xml.reload" value="true" />

设置浏览器是否缓存静态内容

<!-- 设置浏览器是否缓存静态内容 -->
<constant name="struts.serve.static.browserCache" value="false" />

请求参数的编码方式

<!-- 请求参数的编码方式 -->
<constant name="struts.i18n.encoding" value="utf-8" />

http请求系统都重新加载资源文件

<!-- 每次HTTP请求系统都重新加载资源文件,有助于开发 -->
<constant name="struts.i18n.reload" value="true" />

文件上传最大值


<!-- 文件上传最大值 -->
<constant name="struts.multipart.maxSize" value="104857600" />

让struts2支持动态方法调用

<!-- 让struts2支持动态方法调用 -->
<constant name="struts.enable.DynamicMethodInvocation" value="true" />

Action名称中是否还是用斜线

<!-- Action名称中是否还是用斜线 -->
<constant name="struts.enable.SlashesInActionNames" value="false" />

允许标签中使用表达式语法

<!-- 允许标签中使用表达式语法 -->
<constant name="struts.tag.altSyntax" value="true" />

Action名称中是否还是用斜线

<!-- 对于WebLogic,Orion,OC4J此属性应该设置成true -->
<constant name="struts.dispatcher.parametersWorkaround" value="false" />

猜你喜欢

转载自blog.csdn.net/u013806366/article/details/79299230
今日推荐