<?php
include("include/baglan.php");
include("include/fonksiyonlar.php");


ob_start();
session_start();
oturumkontrolana();

?>
<!DOCTYPE html>
<html lang="tr">
    
<head>
        <meta charset="utf-8">
        <meta http-equiv="X-UA-Compatible" content="IE=edge">
        <meta name="viewport" content="width=device-width, initial-scale=1">
        <meta name="description" content="<?=$ayar['site_description']?>">
        <meta name="keywords" content="<?=$ayar['site_keyword']?>">
        <meta name="author" content="<?=$ayar['site_author']?>">
        <link rel="icon" type="image/png" href="../resimler/<?=$ayar['favicon']?>">
        <title><?=$ayar['site_title']?></title>

 
        <link href="https://fonts.googleapis.com/css?family=Poppins:400,500,700,800&amp;display=swap" rel="stylesheet">
        <link href="assets/plugins/bootstrap/css/bootstrap.min.css" rel="stylesheet">
        <link href="assets/plugins/font-awesome/css/all.min.css" rel="stylesheet">
        <link href="assets/plugins/perfectscroll/perfect-scrollbar.css" rel="stylesheet">
        <link href="assets/plugins/apexcharts/apexcharts.css" rel="stylesheet">

      
       
        <link href="assets/css/main.min.css" rel="stylesheet">
        <link href="assets/css/custom.css" rel="stylesheet">

        
    </head>
    <body>

        <div class="page-container">
            <div class="page-header">
                <?php include("include/header.php");?>
            </div>
            <?php include("include/menu.php");?>
            
            
            
            <div class="page-content">
              <div class="main-wrapper">
                 
                   
              
                
             

                
              <?php 
            if($_GET['sil']){
             $idd=$_GET['sil'];
             $simdi=$db->query("delete from iletisim where id='$idd'")->fetch(PDO::FETCH_ASSOC);}?>
             
                <div class="row">
                    <div class="col">
                        <div class="card">
                            <div class="card-body" style="overflow:scroll;">
                               <h5 class="card-title">İletişim Formu </h5>
                                <table class="table invoice-table">
                                            <thead>
                                              <tr>
                                                <th scope="col">Adı Soyadı</th>
                                                <th scope="col">Email</th>
                                                <th scope="col">Phone</th>
                                                <th scope="col">Mesaj</th>
                                                <th scope="col">Tarih</th>
                                                <th scope="col">İşlem</th>
                                              </tr>

                                            </thead>

                                            <tbody>

                                        <?php
                                        $urunlistele = $db->query("select * from iletisim  order by id desc",PDO::FETCH_ASSOC);
                                        if($urunlistele->rowCount()){foreach($urunlistele as $urungoster){
                                        ?>

                                        <tr>
                                            <th scope="row"><?=$urungoster['adi']?></th>
                                            <th scope="row"><?=$urungoster['email']?></th>
                                            <td><?=$urungoster['telefon']?></td>
                                            <td><?=$urungoster['mesaj']?></td>
                                            <td><span class="badge bg-primary"><?=$urungoster['tarih']?></span></td>
                                            <td><a class="silmeAlani" href="?sil=<?=$urungoster['id']?>"><i class="fa fa-trash-o"></i></a></td>
                                        </tr>
                                        <?php } }?>
                                    </tbody>
                                </table>
                            </div>
                        </div>    
                    </div>
                </div>

                
                <div class="row">
                 
                  
                   <div class="col-md-6 col-xl-3">
                  <?php
                  $slidercek111 = $db->query("select * from yorumlar",PDO::FETCH_ASSOC);
				  if($slidercek111->rowCount()){foreach($slidercek111 as $slidergoster111){
				  }
				  }
				  $slidersay111 = $slidercek111->rowCount();
				  ?>
                    <div class="card stat-widget">
                        <div class="card-body">
                            <h5 class="card-title">Yorumlar </h5>
                              <h2><?=$slidersay111?></h2>
                              <p>Toplam Yorum Kaydı(∞)</p>
                              <div class="progress">
                                <div class="progress-bar bg-info progress-bar-striped" role="progressbar" style="width: <?=$slidersay111?>%" aria-valuenow="100000000" aria-valuemin="0" aria-valuemax="100000000"></div>
                              </div>
                        </div>
                    </div>
                  </div>
                   
                  <div class="col-md-6 col-xl-3">
                  <?php
                  $hizmetsec = $db->query("select * from hizmetler",PDO::FETCH_ASSOC);
				  if($hizmetsec->rowCount()){foreach($hizmetsec as $hizmetgoster){
				  }
				  }
				  $hizmetsay = $hizmetsec->rowCount();
				  ?>
                    <div class="card stat-widget">
                        <div class="card-body">
                            <h5 class="card-title">Hizmetler </h5>
                              <h2><?=$hizmetsay?></h2>
                              <p>Toplam Hizmet Kaydı(∞)</p>
                              <div class="progress">
                                <div class="progress-bar bg-info progress-bar-striped" role="progressbar" style="width: <?=$hizmetsay?>%" aria-valuenow="100000000" aria-valuemin="0" aria-valuemax="100000000"></div>
                              </div>
                        </div>
                    </div>
                  </div>
                  
                  
                   <div class="col-md-6 col-xl-3">
                  <?php
                  $sayfasec = $db->query("select * from sayfalar",PDO::FETCH_ASSOC);
				  if($sayfasec->rowCount()){foreach($sayfasec as $sayfagoster){
				  }
				  }
				  $sayfasay = $sayfasec->rowCount();
				  ?>
                    <div class="card stat-widget">
                        <div class="card-body">
                            <h5 class="card-title">Sayfalar </h5>
                              <h2><?=$sayfasay?></h2>
                              <p>Toplam Sayfa Kaydı(∞)</p>
                              <div class="progress">
                                <div class="progress-bar bg-info progress-bar-striped" role="progressbar" style="width: <?=$sayfasay?>%" aria-valuenow="100000000" aria-valuemin="0" aria-valuemax="100000000"></div>
                              </div>
                        </div>
                    </div>
                  </div>
                  
                  
                  
                  
                   <div class="col-md-6 col-xl-3">
                  <?php
                  $slidercek = $db->query("select * from slider",PDO::FETCH_ASSOC);
				  if($slidercek->rowCount()){foreach($slidercek as $slidergoster){
				  }
				  }
				  $slidersay = $slidercek->rowCount();
				  ?>
                    <div class="card stat-widget">
                        <div class="card-body">
                            <h5 class="card-title">Slider </h5>
                              <h2><?=$slidersay?></h2>
                              <p>Toplam Slider Kaydı(∞)</p>
                              <div class="progress">
                                <div class="progress-bar bg-info progress-bar-striped" role="progressbar" style="width: <?=$slidersay?>%" aria-valuenow="100000000" aria-valuemin="0" aria-valuemax="100000000"></div>
                              </div>
                        </div>
                    </div>
                  </div>
                  
                  
                  
                   
                   <div class="col-md-6 col-xl-3">
                  <?php
                  $slidercek11 = $db->query("select * from galeri",PDO::FETCH_ASSOC);
				  if($slidercek11->rowCount()){foreach($slidercek11 as $slidergoster11){
				  }
				  }
				  $slidersay11 = $slidercek11->rowCount();
				  ?>
                    <div class="card stat-widget">
                        <div class="card-body">
                            <h5 class="card-title">Galeri </h5>
                              <h2><?=$slidersay11?></h2>
                              <p>Toplam Galeri Kaydı(∞)</p>
                              <div class="progress">
                                <div class="progress-bar bg-info progress-bar-striped" role="progressbar" style="width: <?=$slidersay11?>%" aria-valuenow="100000000" aria-valuemin="0" aria-valuemax="100000000"></div>
                              </div>
                        </div>
                    </div>
                  </div>
                  
                  
                </div>
            </div>
        </div>
    </div>
        
        <script src="assets/plugins/jquery/jquery-3.4.1.min.js"></script>
        <script src="https://unpkg.com/@popperjs/core@2"></script>
        <script src="assets/plugins/bootstrap/js/bootstrap.min.js"></script>
        <script src="https://unpkg.com/feather-icons"></script>
        <script src="assets/plugins/perfectscroll/perfect-scrollbar.min.js"></script>
        <script src="assets/plugins/apexcharts/apexcharts.min.js"></script>
        <script src="assets/js/main.min.js"></script>
        <script src="assets/js/pages/dashboard.js"></script>
    </body>
   <script src="https://use.fontawesome.com/ca9a29c061.js"></script>
  <?php include("silme.php");?>
</html>