---
title: "后台action处理使页面弹出提示框"
author: "xu0213"
date: "2014-11-19T09:23:23Z"
tags: []
categories: ["编程语言"]
slug: "action"
draft: false
lastmod: "2014-11-19T09:23:23Z"
id: 2157828
url: "https://xu0213.iteye.com/blog/2157828"
---

PrintWriter out=null; 
try { 
//设置回发内容编码       
ServletActionContext.getResponse().setContentType("text/html;charset=utf-8");  
out = ServletActionContext.getResponse().getWriter(); 
} catch (IOException e) { 
     e.printStackTrace(); 
} 
out.print("<script>alert('请先删除下级数据！');history.go(-1);</script>");                
     return null;