在表单中加一个<input type="hidden" name="action" value="insert">
然后在php中加一个if($_POST['action'] == 'insert'){insert语句}

解决方案 »

  1.   

    好主意!
    不过想了下,可以搞个header()函数重新定位页面,你觉得呢?我去试下
      

  2.   

    header的时候转到其他页面
    提交表单的页面修改
    <body onbeforeunload="window.location.replace('')">
      

  3.   

    当然会这样,你可以用cookie+timestam来限制xx秒中只能提交一次
      

  4.   

    提交完一次后用 unset($_POST);
      

  5.   

    设置变量最好,处理完了用exit也是个主意
      

  6.   

    Redirect to another page like success.htm after operating the data in the script page.