韩志成你给我俩等着

This commit is contained in:
2025-04-10 02:32:42 +08:00
parent 188fe51b24
commit 29c65ddc02
8 changed files with 599 additions and 27 deletions

View File

@@ -1,27 +1,3 @@
<?php
include_once("../../common/init.php");
check_loginuser();
if ($_POST){
$data = array();
$row = db_get_row("select * from yajin where userid='". $_SESSION["studentid"] ."'");
if ($row["id"]) {
if($_POST["price"]+$row["price"]<300){
goBakMsg("预存款不能少于300元");
die;}else{db_query("update yajin set price=price+".$_POST["price"]." where id=".$row["id"]);}
}
else{if($_POST["price"]<300){goBakMsg("预存款不能少于300元");die;}}
$data["price"] = "'".$_POST["price"]."'";
$data["studentid"] = "'".$_SESSION['stuname']."'";
$data["userid"] = "'".$_SESSION['studentid']."'";
if ($row["id"]) {
} else {
db_add("yajin",$data);
}
urlMsg("提交成功", "main.php");
die;
}
?>
<?php include_once("base.php");?>
<body>
<table width="100%" border="0" cellpadding="0" cellspacing="0">
@@ -44,7 +20,7 @@
<table width="100%">
<tr>
<td colspan="2">
<form name="add" method="post" action="?" enctype="multipart/form-data">
<form name="add" method="post" action="submit.php" enctype="multipart/form-data">
<table width="100%" class="cont">
<tr>