You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
70 lines
1.8 KiB
70 lines
1.8 KiB
<?php
|
|
|
|
//Function to filter the form input
|
|
function user_input( $data ) {
|
|
$data1 = trim($data);
|
|
$data2 = stripslashes($data1);
|
|
$data3 = htmlspecialchars($data2);
|
|
return $data3;
|
|
}
|
|
|
|
|
|
$contractno = user_input($_POST["contractno"]);
|
|
$facilityno = user_input($_POST["facilityno"]);
|
|
$combono = user_input($_POST["combono"]);
|
|
$repairerid = user_input($_POST["repairerid"]);
|
|
$repairername = user_input($_POST["repairername"]);
|
|
$duedate = user_input($_POST["duedate"]);
|
|
|
|
/*
|
|
$actualdate = user_input($_POST["actualdate"]);
|
|
$item = user_input($_POST["item"]);
|
|
$item_detail = user_input($_POST["item_detail"]);
|
|
$result = user_input($_POST["result"]);
|
|
# $evidences = user_input($_POST["evidences"]);
|
|
$descriptons = user_input($_POST["descriptons"]);
|
|
$customer_login_id = user_input($_POST["customer_login_id"]);
|
|
$customer_login_name = user_input($_POST["customer_login_name"]);
|
|
$stars = user_input($_POST["stars"]);
|
|
$details = user_input($_POST["details"]);
|
|
$customer_signature = user_input($_POST["customer_signature"]);
|
|
*/
|
|
|
|
$creater = user_input($_POST["creater"]);
|
|
$create_at = date('Y/m/d H:i:s');
|
|
|
|
|
|
|
|
|
|
|
|
/*
|
|
|
|
if(empty($_POST["name"])) {
|
|
$name_error = "Name is required";
|
|
} else {
|
|
$name = user_input($_POST["name"]);
|
|
|
|
if(!preg_match("/^[a-zA-Z ]*$/", $name)) {
|
|
$name_error = "Only letter and white space are allowed";
|
|
}
|
|
}
|
|
|
|
|
|
/*
|
|
if(empty($_POST["website"])) {
|
|
$website_error = "Website address is required";
|
|
} else {
|
|
$website = user_input($_POST["website"]);
|
|
|
|
if(!preg_match("/\b(?:(?:https?|ftp):\/\/|www\.)[-a-z0-9+&@#\/%?=~_|!:,.;]*[-a-z0-9+&@#\/%=~_|]/i", $website)) {
|
|
$website_error = "Invalid website URL";
|
|
}
|
|
}
|
|
|
|
if(empty($_POST["comment"])) {
|
|
$comment = "";
|
|
} else {
|
|
$comment = user_input($_POST["comment"]);
|
|
}
|
|
*/
|
|
?>
|
|
|