$value){ $data[$key] = stripslashes_array($value); } return $data; }else{ return stripslashes($data); } } function addslashes_array($data) { if (is_array($data)){ foreach ($data as $key => $value){ $data[$key] = addslashes_array($value); } return $data; }else{ return addslashes($data); } } ?> 0) { if (SingleResult("SELECT `Status` FROM `wwbestelinfo` WHERE `OrderId`=\"" . $_POST['OrderId'] . "\"")==0) { $OrderId = $_POST['OrderId']; } else $OrderId = CalcNewOrderId(); } else $OrderId = $_POST['OrderId']; } elseif (isset($_GET['OrderId'])) { if (SingleResult("SELECT COUNT(*) FROM `wwbestelinfo` WHERE `OrderId`=\"" . $_GET['OrderId'] . "\"")>0) { if (SingleResult("SELECT `Status` FROM `wwbestelinfo` WHERE `OrderId`=\"" . $_GET['OrderId'] . "\"")==0) { $OrderId = $_GET['OrderId']; } else $OrderId = CalcNewOrderId(); } else $OrderId = $_GET['OrderId']; } else { $OrderId = CalcNewOrderId(); } ?>