-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathyaz.php
84 lines (48 loc) · 1.3 KB
/
yaz.php
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
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
<?php
include 'header.php';
?>
<div class="contentGrid ">
<div class="container">
<form class="yazForm" method="post">
<div class="row">
<div class="col-md-6 col-12">
<div class="input-field">
<input type="text" id="name" name="name" required >
<label for="name">Name:</label>
</div>
</div>
<div class="col-md-6 col-12">
<div class="input-field">
<input type="text" id="surname" name="surname" required >
<label for="surname">Surname:</label>
</div>
</div>
<div class="col-md-12 col-12 mt-3">
<textarea class="my-0" name="content" id="content" cols="30" rows="10" placeholder="İçerik Ekleyin" required=""></textarea>
</div>
<div class="col-md-3 mt-3 mx-auto col-6">
<div class="inputSubmit">
<input type="submit"name="submit" value="Gönder">
</div>
</div>
</form>
</div>
</div>
<?php
include 'baglan.php';
$name=$_POST["name"];
$surname=$_POST["surname"];
$content=$_POST["content"];
$submit=$_POST["submit"];
if (isset($submit)) {
$ekle = $bag->ekle("codes", "name,surname,content", array("$name", "$surname","$content"));
if ($ekle){
echo "id: " .$ekle. " kayıt eklendi";
}else{
echo "Kayit eklenmedi";
}
} else {
echo "boş yerler var";
}
include "footer.php";
?>