Vous êtes connecté en tant que anonymous Se Deconnecter
Browse code

commit initial de la branch template-meny

git authored on 14/03/2019 10:30:11
Showing 1 changed files
1 1
new file mode 100644
... ...
@@ -0,0 +1,21 @@
1
+<?php
2
+
3
+require OBJETS_PATH.DIRECTORY_SEPARATOR."host.class.php";
4
+
5
+$path = PATH_URL;
6
+$bdd = new Bdd();
7
+
8
+Host::addHost($bdd,$_POST['ip'],$_POST['nom']);
9
+
10
+switch($_POST['from']){
11
+    case "vlan-zone+" :
12
+    case "vlan-zone" :
13
+        header("Location: $path{$_POST['from']}/vlan/{$_POST['vlan']}/alert/2/host/{$_POST['ip']}");
14
+        break;
15
+    case "ip-zone+" :
16
+    case "ip-zone" :
17
+        header("Location: $path{$_POST['from']}/motif-ip/{$_POST['motif-ip']}/alert/2/host/{$_POST['ip']}");
18
+        break;
19
+    default:
20
+        header("Location: $path");
21
+}
0 22
\ No newline at end of file