admin/goods_add.php
(开头部分) 6KB这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。
<?php
include("check_login.php");
include("../conn.php");
include("fun.php");
//添加汽车
if($action=="add")
{
if(is_numeric($shichangjia)==false || is_numeric($huiyuanjia)==false)
{
echo "<script>alert('价格只能为数字!');history.back();</script>";
exit;
}
if(is_numeric($shuliang)==false)
{
echo "<script>alert('数量只能为数字!');history.back();</script>";
exit;
}
if(ceil(($huiyuanjia/$shichangjia)*100)<=80)
$tejia=1;
else
$tejia=0;
$exname=strtolower(substr($_FILES['upfile']['name'],(strrpos($_FILES['upfile']['name'],'.')+1)));
$uploadfile = getname($exname);
move_uploaded_file($_FILES['upfile']['tmp_name'], $uploadfile);
if(trim($_FILES['upfile']['name']!=""))
{
$uploadfile="admin/".$uploadfile;
}
else
{
$uploadfile="";
}
$addtime=date("Y-m-d");
mysql_query("insert into goods(mingcheng,jianjie,addtime,xinghao,tupian,typeid,shichangjia,huiyuanjia,pinpai,tuijian,shuliang,cishu,tejia)values('$mingcheng','$jianjie','$addtime','$xinghao','$uploadfile','$typeid','$shichangjia','$huiyuanjia','$pinpai','$tuijian','$shuliang','0','$tejia')",$conn);
echo "<script>alert('汽车".$mingcheng."添加成功!');window.location.href='goods.php';</script>";
}
?>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>添加汽车</title>
<link rel="stylesheet" type="text/css" href="images/admincp.css">
</head>
<body topmargin="0" leftmargin="0" bottommargin="0">
<table width="720" border="0" align="center" cellpadding="0" cellspacing="0">
<tr>
<td height="30" bgcolor="#E7F3FB"><div align="center" >添加汽车</div></td>
</tr>
<tr>
<td height="253" bgcolor="#E7F3FB"><table width="720" border="0" cellpadding="0" cellspacing="1">
<script language="javascript">
function chkinput(form)
{
if(form.mingcheng.value=="")
后面还有 146 行代码,购买后查看完整代码
24 小时内免费解锁 3 个项目,之后 1 算力/个。 规则说明
AI 解读 AI
登录后可用,每次 10 算力,解读结果公开显示在下面。
还没有人解读过这个文件。