提交表单后,我要检查$totaalaantal
是否不大于$aantalcompleet + $ready
这是代码的一小部分:
if(isset($_POST['gereed'])){
$gereed = ($_POST['gereed']);
$ready = ($_POST['complete']);
$base = ($_POST['base']);
$lot = ($_POST['lot']);
$split = ($_POST['split']);
$sub = ($_POST['sub']);
$seq = ($_POST['seq']);
if($aantalcompleet + $ready > $totaalaantal){
//Confirm popup
}else{
if($aantalcompleet + $ready >= $totaalaantal){
LaborTicket($base, $lot ,$split, $sub, $seq, $machine, $ready);
stopjob($Employee, $base, $lot, $split, $sub, $seq, $machine);
}else{
LaborTicket($base, $lot ,$split, $sub, $seq, $machine, $ready);
echo "<script>window.location = 'dashboard.php?machine=".$machine."&search=&base=".$base."&lot=".$lot."&split=".$split."&sub=".$sub."&seq=".$seq."&part=".$part."'</script>";
}
$_POST = array();
}
}
在if($aantalcompleet + $ready > $totaalaantal){
部分之后,我想要一个带有YES或NO的弹出窗口。
如果否,则不执行任何操作。
如果是,请执行一些php函数
欢迎任何建议:)