---
title: "struts2 配置全局错误页面"
author: "harbey"
date: "2009-11-24T17:14:34Z"
tags: []
slug: "struts2"
draft: false
lastmod: "2009-11-24T17:14:34Z"
id: 524670
url: "https://harbey.iteye.com/blog/524670"
---

```java

	<package name="my_struts_default" extends="struts-default"
		abstract="true">
		<global-results>
			<result name="exception">/common/error.jsp</result>
		</global-results>
		<global-exception-mappings>
			<exception-mapping result="exception"
				exception="java.lang.Exception">
			</exception-mapping>
		</global-exception-mappings>
	</package>

```