日期:2014-05-18  浏览次数:20737 次

判断表单是否提交
<%
//这样是取不到已经提交的表单值的,有其他办法判断改表单是否提交嘛??
String   post=request.getParameter( "post ");
System.out.println( "post= "+post);
if   ((post!=null)&&post.equals( "1 "))   {
...
}
%>
<form   name= "PostForm "   method= "post "   enctype= "multipart/form-data "   action= " ">
<input   name= "post "   type= "hidden "   value= "1 ">

  <input   name= "attach "   type= "submit "     value= "发送 "   >
</form>



------解决方案--------------------
给form的action增加一个参数,比如isPost=1,下次就判断isPost是不是1就完了