求大神帮忙看看哪里错了
if (!isset($_SESSION["sn"])){
$_SESSION['sn']=0;
setcookie('sn',$sn,time()+1);
if($_POST["submit"]){
if($sn=3)
{
alert("抱歉,您已经点击了3次");
location.href="//m.sbmmt.com/m/faq/zp.php";
exit();
}
elseif ($sn=="tull")
{
alert("123");
location.href="//m.sbmmt.com/m/faq/zp.php";
exit();
}
$newitem=$_POST["zp_user"];
$sql="insert into vote (awards,sn,pnone) values (1,'$sn',1)";
if(mysql_query($sql))
{
$sn==$_SESSION['sn']+1;
}}
if($_POST["submit2"]){
if(empty($_POST['sn']))
$_SESSION['zp_user']=$_POST['pnone'];
$sql="insert into zp_user values('".($_POST['sn'])."')";
if(mysql_query($sql))
{
}
}}
已抢23833个
抢已抢118348个
抢已抢139589个
抢已抢6358个
抢已抢36786个
抢已抢67008个
抢