diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..e7d3097 --- /dev/null +++ b/.gitignore @@ -0,0 +1,4 @@ + +cgi-bin/conn\.conn + +node_modules/ diff --git a/ADMIN/content.php b/ADMIN/content.php old mode 100644 new mode 100755 diff --git a/ADMIN/header.php b/ADMIN/header.php old mode 100644 new mode 100755 diff --git a/ADMIN/links.php b/ADMIN/links.php old mode 100644 new mode 100755 diff --git a/ADMIN/login.php b/ADMIN/login.php old mode 100644 new mode 100755 diff --git a/ADMIN/menu.php b/ADMIN/menu.php old mode 100644 new mode 100755 index 6a97088..7bb640f --- a/ADMIN/menu.php +++ b/ADMIN/menu.php @@ -71,8 +71,8 @@
diff --git a/ADMIN/sheets/advertisement/add.php b/ADMIN/sheets/advertisement/add.php index fcb92b3..97768bb 100755 --- a/ADMIN/sheets/advertisement/add.php +++ b/ADMIN/sheets/advertisement/add.php @@ -12,6 +12,9 @@ $uid = 0; $append = 0; + $order = isset($_POST['other_order']) ? addslashes(trim($_POST['other_order'])) : "Salerno"; + $ouid = isset($_POST['other_order_number']) ? addslashes(trim($_POST['other_order_number'])) : 0; + if(is_uploaded_file($_FILES['append']['tmp_name'])){ $filename = date("YmdHis")."-".preg_replace('/[^a-zA-Z0-9\-\._]/','_', $_FILES['append']['name']); $filesize = ($_FILES['append']['size'] < 1000000) ? round($_FILES['append']['size'] / 1000)."k" : round($_FILES['append']['size'] / 1000000)."M"; @@ -21,7 +24,7 @@ $append = mysqli_insert_id($conn); } - $q=mysqli_query($conn, "INSERT INTO advertisement VALUES(null, $uid, '".addslashes(trim($_POST['full_name']))."', + $q=mysqli_query($conn, "INSERT INTO advertisement VALUES(null, $uid, '".$order."', $ouid, '".addslashes(trim($_POST['full_name']))."', '".addslashes(trim($_POST['email']))."', '".trim(conv_date_en($_POST['date']))."', '".addslashes(nl2br($_POST['text']))."', '".addslashes(trim($_POST['city']))."', '".addslashes(trim($_POST['contact_phone']))."', '".addslashes(trim($_POST['contact_email']))."', $append, '".$_POST['type']."', @@ -56,6 +59,22 @@ Nome e Cognome + +