<%@ page contentType="text/html; charset=gb2312"%>
<%@ page import="java.sql.*"%> 
<%@ page import="java.util.*"%>
<%@ page import="java.util.Date"%>
<%@ page import="java.text.*"%>
<%@ include file="../admin/checkmaster.jsp"%>
<%@ include file="../inc/conn.jsp"%>
<%
String sql,id,content,title;
ResultSet rs;
id = request.getParameter("id");
title = new String(request.getParameter("title").getBytes("iso-8859-1"));
content = new String(request.getParameter("content").getBytes("iso-8859-1"));
if(id!=null){
     sql="update sms set title='"+title+"',content='"+content+"' where id="+id;
     stmt.executeUpdate(sql);
     }
else
{
sql="insert into sms(title,content,bbssystem) values('"+title+"','"+content+"',1)";
stmt.executeUpdate(sql);
}
response.sendRedirect("managesms.jsp");
%>