
<div class="content-body">
<div class="container-fluid">
<div class="page-header">
<div class="page-title">
<h4>İstatik Ekle</h4>
</div>
</div>

<?php
if($_GET['islem']=='duzenle'){
    
    $guncelle = $db->query("select * from istatik where id='{$_GET['id']}'")->fetch(PDO::FETCH_ASSOC);
}
?>

<form method="post" action="include/fonksiyonlar.php" enctype="multipart/form-data">
<div class="card">
<div class="card-body">
<div class="row">
<div class="col-lg-6 col-sm-6 col-12">
<div class="form-group">
<label>İstatik Sayısı</label>
<input type="text" class="form-control input-rounded" name="sira" value="<?=$guncelle["sira"]?>">
</div>
</div>
<div class="col-lg-6 col-sm-6 col-12">
<div class="form-group">
<label>İstatik Adı</label>
<input type="text" class="form-control input-rounded" name="adi" value="<?=$guncelle["adi"]?>">
</div>
</div>



<div class="col-lg-12 col-sm-12 col-12">
<div class="form-group">
<label>İstatik Durum </label>
<select class="default-select form-control wide mb-3" name="durum">
<option value="0" <?php if($guncelle["durum"]==0){ echo "selected";}?>>Sitede Göster</option>
<option value="1" <?php if($guncelle["durum"]==1){ echo "selected";}?>>Sitede Gizle</option>
</select>
</div>
</div>

<div class="col-lg-12">
<div class="form-group">
<label>İstatik İcon</label>
<textarea class="form-control input-rounded" class="form-control" name="linki"><?=$guncelle["linki"]?></textarea>
</div>
</div>




                     
                                 

<br><br><br><br>

<div class="col-lg-12">
    <?php if($_GET['islem']=='duzenle'){?>
<button class="btn btn-primary mb-2" type="submit" name="istatik-guncelle">İstatik Güncelle</button>
<input type="hidden" name="id" value="<?=$guncelle["id"]?>">
    <input type="hidden" name="link" value="../istatik-ekle?islem=duzenle&id=<?=$guncelle["id"]?>">

<?php } else {?>
    <input type="hidden" name="link" value="../<?=$seo?>">

<button class="btn btn-primary mb-2" type="submit" name="istatik-ekle">İstatik Ekle</button>

<?php }?>
</div>
</div>
</div>
</div>
</form>
</div>
</div>