-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathpost.php
More file actions
37 lines (30 loc) · 825 Bytes
/
post.php
File metadata and controls
37 lines (30 loc) · 825 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
<?php
// define variables and set to empty values
$name = $email = $gender = $comment = $website = "";
if ($_SERVER["REQUEST_METHOD"] == "POST"&&$_POST["email"]!="") {
$name = test_input($_POST["name"]);
$email = test_input($_POST["email"]);
$surname = test_input($_POST["surname"]);
$comment = test_input($_POST["comment"]);
$gender = test_input($_POST["gender"]);
$secim=test_input($_POST["secim"]);
echo "Adı: ",$name;
echo "<br>";
echo "Soyadı: ",$surname;
echo "<br>";
echo "E-Mail: ",$email;
echo "<br>";
echo "Yorumu: ",$comment;
echo "<br>";
echo "Cinsiyyeti: ",$gender;
echo "<br>";
echo "Seçimi: ",$secim;
header("gonderildi");
}
function test_input($data) {
$data = trim($data);
$data = stripslashes($data);
$data = htmlspecialchars($data);
return $data;
}
?>