private void cmdOK_ServerClick(object sender, System.EventArgs e) { BBSClass bbs = new BBSClass(); BBSForumItem item = new BBSForumItem(); string itemcontent = ViewState["Content"] + Content.Value; item.BoardID = Int32.Parse(boardid); item.Title = MyTitle.Value.Replace("<","<"); item.Title = item.Title.Replace(">",">"); if(item.Title.Trim()=="") item.Title = "�ޱ���"; item.Content = itemcontent.Replace("<","<"); item.Content = item.Content.Replace(">",">"); item.Sender = username; item.IP = Request.ServerVariables["remote_addr"].ToString(); item.Bulletin = (cbx_bulletin==null)?false:cbx_bulletin.Checked; item.SysBulletin = (cbx_bulletin==null)?false:cbx_sysbulletin.Checked; item.DeskTop = (cbx_DeskTop==null)?false:cbx_DeskTop.Checked; item.ItemID = bbs.SendItem(item); if(ViewState["filename"]!=null && ViewState["filename"].ToString().Trim()!="") item.Attach(ViewState["filename"].ToString()); try { Response.Write("<script>if(opener!=null) {opener.location.reload();opener.parent.parent.header.location.reload();location.href='Display.aspx?ItemID="+item.ItemID.ToString()+"&BoardID="+item.BoardID.ToString()+"'}</script>"); } catch(Exception ex) { UDS.Components.Error.Log(ex.Message); Server.Transfer("../../Error.aspx"); } }