WebRoot/yjy/action/releaseAction.jsp
(完整代码) 1KB<%@ page language="java" import="java.util.*,com.accp.myShopping.yjy.bean.*,com.accp.myShopping.yjy.dao.*" pageEncoding="utf-8"%>
<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
%>
<%
request.setCharacterEncoding("utf-8");
TopicBean bean=new TopicBean();
int tsid=Integer.parseInt(request.getParameter("select_stlye2"));
AddsctionCountDao.UpdateSctionCount(tsid);
bean.setTsid(tsid);
UserBean ubean=(UserBean)session.getAttribute("userInfos");
try{bean.setTuid(ubean.getU_id());
Userdao.adduserscore(ubean.getU_id());}
catch(Exception e){e.printStackTrace();}
bean.setTtopic(request.getParameter("topicname"));
bean.setTcontents(request.getParameter("myTextarea"));
Topicdao dat=new Topicdao();
int i=dat.insertTopic(bean);
if(i>0)
{
out.println("<script>alert('发表成功'); location.href='../JSP/BBSindex.jsp';</script>");
}else{
out.println("<script>alert('发表失败!'); location.href='../JSP/BBSindex.jsp';</script>");
}
%>
24 小时内免费解锁 3 个项目,之后 1 积分/个。 规则说明
AI 解读
登录后可用,每次 10 积分,解读结果公开显示在下面。
还没有人解读过这个文件。
