-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathpersonel-ekle.php
45 lines (37 loc) · 993 Bytes
/
personel-ekle.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
<?php
session_start();
if((!isset($_SESSION["login"]))||($_SESSION["yetki"]=="0")){
?>
<meta http-equiv="refresh" content="0;URL=giris.php">
<?php
} else
{
?>
<!-- GİRİŞ KONTROL -->
<?php include("header.php") ?>
<?php include("kontrol/veritabani.php") ?>
<section id="content">
<?php
$adsoyad=$_POST['adsoyad'];
$sifre=md5($_POST['sifre']);
$eposta=$_POST['eposta'];
$telefon=$_POST['telefon'];
$kadi=$_POST['kadi'];
if(isset($_POST['yetki'])) {
$yetki=1;
} else {
$yetki=0;
}
$ayarguncelle=$connection->query("insert into personel (kadi,sifre,eposta,telefon,adsoyad,yetki) values ('$kadi','$sifre','$eposta','$telefon','$adsoyad','$yetki')") or die ("bir hata olustu...");
if($ayarguncelle){
$durum="<h2>İşlem Başarılı</h2>";
}else{
$durum="<h2>Hiç veri girmediniz..</h2>";
}
echo"$durum";
echo" <meta http-equiv=\"refresh\" content=\"0;url=personel.php\"> ";
?>
</section>
<!-- GİRİŞ KONTROL -->
<?php include("footer.php"); ?>
<?php } ?>