yingpin_Add.php

(开头部分) 6KB

这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。

<?php
require("top.php");
if($_SESSION[log_type]=="" || $_SESSION[log_name]=="")
{
echo "<script>alert('请登录');location.href='login.php';</script>";
	exit;
}
if($id!="")
{//取出yingpin表数据用于修改
	$sql="select * from yingpin where id=$id";
	$result=mysql_query($sql);
	$data=mysql_fetch_array($result);
}
$pubtype=$_SESSION[log_type];
$puname=$_SESSION[log_name];
if($act=="save")
{	$strsubject=implode(",",$subject);

	if($id!="")
	{
		$pic=upload_file("pic",$data[pic]);

	$sql="update yingpin set name='$name',subject='$strsubject',pic='$pic',sex='$sex',age='$age',marry='$marry',degree='$degree',star='$star',jingyan='$jingyan',intro='$intro',areaid='$areaid',tel='$tel',qq='$qq',gongzi='$gongzi',address='$address' where id=$id";
$res=mysql_query($sql);
	if($res)
	{
	echo "<script>alert('修改成功');location.href='yingpin.php';</script>";
	exit;
	}
	else
	{
	exit ("修改失败了");
	}
	}
			$pic=upload_file("pic","");
	//$strsubject=implode(",",$subject);

	$sql="insert into yingpin (name,subject,pic,sex,age,marry,degree,star,jingyan,intro,areaid,tel,qq,pubtype,puname,states,addtime,gongzi,address) values ('$name','$strsubject','$pic','$sex','$age','$marry','$degree','$star','$jingyan','$intro','$areaid','$tel','$qq','$pubtype','$puname','0',NOW(),'$gongzi','$address')";

$res=mysql_query($sql);
	if($res)
	{
	echo "<script>alert('添加成功');location.href='yingpin.php';</script>";
	exit;
	}
	else
	{
	exit("添加失败了");
	}
}




?>

<table width="960" border="0" cellspacing="0" cellpadding="0"><tr><td height="5"></td></tr></table>
<script type="text/javascript">


后面还有 206 行代码,购买后查看完整代码

24 小时内免费解锁 3 个项目,之后 1 算力/个。 规则说明

AI 解读 AI

登录后可用,每次 10 算力,解读结果公开显示在下面。

还没有人解读过这个文件。