后台传值
//getRequest().setAttribute传值,没有set,get方法
前台取值
<s:select list="%{#request.list1}" id="stOrg" name="stOrg"theme="simple" headerKey=""headerValue="--请选择--" listKey="id" listValue="orgName"></s:select>
<font color="red"> *</font>
//jsp页面提交表单前弹出一个对话框是否确定
javascript:if(confirm('是否确定退团?')){window.location.href='/stzc/StUserandorg/delete.do?org_id=12';}
//按钮单击事件跳转
<input type="submit" id="submitButton" value="创建社团活动" class="btn"onclick="javascript:window.location='${ctx}/stzc/StOrgactivity/create.do'">
//后退按钮
onclick="history.go(-1)"
//按钮右对齐
<input style="float:right" type="button" class="btn" value="返回" onclick="history.go(-1)" />
//表格消除边框
<td style="border:none"></td>
//表单提交验证函数
<form id="queryForm" name="queryForm" onsubmit="javascript:check();"action="<c:url value='/stzc/StOrgactivity/save.do'/>" method="post" style="display: inline;">
//后台存session里的值删除
后台
getRequest().getSession().setAttribute("error", ERROR);
前台
<input type="hidden" value="${error}" id="error" name="error" />
<%
session.removeAttribute("error");
%>
<script>
function error(){
var error = document.getElementById('error').value;
if(error!=""){
alert(error);
}
}
</script>
//导出表格时不会出现时间样式
<td class="celltitle">
${map[item.org_id] }/${item.stOrg.orgNum }
</td>
//关闭按钮
<input type="button" id="submitButton" value="关 闭" class="btn" onclick="javascript:window.close();">