<?php include 'sesion.php'; ?> 
 <?php include '../url_amigable.php';?>
 <?





  $N2 = 0;

  include 'concha.php';





$sql = "SELECT * FROM chat WHERE ver = 'no' ";


$consulta = $conn->query($sql);


$consulta = $conn->query($sql);


{





$N2 = $N2 + 1;

$m_mensajes = $N2;



}


$consulta->free_result();








  $N = 0;


  include 'concha.php';





$sql = "SELECT * FROM comentarios WHERE ver = 'no' ";


$consulta = $conn->query($sql);


$consulta = $conn->query($sql);


{





$N = $N + 1;


$m_comentarios = $N;


}


$consulta->free_result();








  $N = 0;


  include 'concha.php';





$sql = "SELECT * FROM fotosoyentes WHERE ver = 'no' ";


$consulta = $conn->query($sql);


$consulta = $conn->query($sql);


{





$N = $N + 1;

$m_fotos = $N;



}


$consulta->free_result();







  $N = 0;


  include 'concha.php';





$sql = "SELECT * FROM avisos WHERE ver = 'no' ";


$consulta = $conn->query($sql);


$consulta = $conn->query($sql);


{





$N = $N + 1;

$m_avisos = $N;



}


$consulta->free_result();

$m_tot = $m_mensajes + $m_comentarios + $m_fotos + $m_avisos;
?>
<!DOCTYPE html>
<html lang="es">
<head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
	<!-- Required meta tags -->
	
	<meta name="description" content="Panel de Administracion">
	<meta name="author" content="<?php echo $nombresitio ?>">
	<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
  <title><?php echo $nombresitio ?> - Panel de Administracion</title>
  <!--link href='http://fonts.googleapis.com/css?family=Oswald' rel='stylesheet' type='text/css'-->
  <link href="https://fonts.googleapis.com/css?family=Montserrat:100,100i,200,200i,300,300i,400,400i,500,500i,600,600i,700,700i,800,800i,900&display=swap" rel="stylesheet"> 
  <link rel="shortcut icon" href="" type="image/x-icon">
	<link rel="apple-touch-icon" href="">

	<!-- Bootstrap CSS -->
<link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/4.3.1/css/bootstrap.min.css" integrity="sha384-ggOyR0iXCbMQv3Xipma34MD+dH/1fQ784/j6cY/iJTQUOhcWr7x9JvoRxT2MZw1T" crossorigin="anonymous">
  <!-- Link to your css file -->
	<link rel="stylesheet" href="">
<script src="https://code.jquery.com/jquery-3.4.1.min.js" integrity="sha256-CSXorXvZcTkaix6Yvo6HppcZGetbYMGWSFlBw8HfCJo=" crossorigin="anonymous"></script>
  <!--script type="text/javascript" src="//recursos.radiosnethosting.com/ckeditor/ckeditor.js"></script-->
 
    <style>

        .carousel-cell {
          width: 66%; 
          margin-right: 5px;
        }

        .display-flex{
            display: flex;
            justify-content: center;
            align-items: center;
        }

        *{
            border-radius: 0!important;
            
        }

        body {
            background: #e4e4e4;
        }

        .btn, a, h1, h2, h3, h4, h5, h6, b{
          font-family: 'Montserrat', sans-serif;
        }

        .btn, h1, h2, h3, h4, h5, h6 {
          font-weight: 600;
        }

        .navbar {
            position: relative;
        min-height: 50px;
        padding-bottom:  20px;
        /* border: 1px solid transparent; */
            
        }
        
      .btn-primary {
        color: #fff!important;
        background-color: #0066FF;
        border-color: #0066FF;
            }
        
        .page-header{
            margin: 0;
            padding: 1em;
            background-color: #0066FF;
            border: 0;
            text-align:center;
        }
        
        .page-header h2{
            
            color: #ffffff;
            font-weight: bold;
        }
        
        .bloqueAzul{
          /*  background-color: #0066FF;*/
          /* border: 1px solid #e4e4e4;*/
          /*  padding: 1em;*/
            text-align: center;
        }
        
        .bloqueAzul .div {
          border: 1px solid #e4e4e4;  
            background-color: #fff;
        }
        
        ul{
            list-style: none;
            padding: 0;
        }
        
        .far{
            color:#0066FF;
        } 
        .faso {
            color:#fff;
        } 
        
        .colorAzul h3{
            color:#0066FF;
            
        }
        
    </style>

    <script language=javascript>
      function ventanaSecundaria (URL){
        window.open(URL,"ventana1","width=550,height=450,scrollbars=NO")
      }
    </script>

</head>
<body>
<div class="container" style="background-color:#F1F2ED;">
        
        <?php 
            
            if($estiloweb == 9 || $estiloweb == 85 || $estiloweb == 86) {
                
                include 'menu_estilo9.php'; 
            } else {
                
                include 'menu.php';  
            }
     
    ?>
    
</div>
<div role="main" style="background-color:#fff;min-height:80vh;<?php if($estiloweb == 9 || $estiloweb == 85 || $estiloweb == 86){echo 'margin-top:120px;';}?>" class="container pt-3">
    
            <div class="page-header" style="text-align:center;">
  
                <h2><? echo $sdfsdf ?>Noticias en borrador</h2>

            </div>

            <div class="col-12 my-3 text-center" >


<form id="form1" name="form1" method="GET" action="buscar_noticias.php">
    
    <div class="text-center mb-4 border-bottom">
                   
                   <label>BUSCAR UNA NOTICIA</label>  
                   
                   <input name="busqueda" type="text" class="form-control" id="busqueda" />
                    <button class="btn btn-primary mb-4" id="button" >Buscar</button>
                    
    </div>
</form>
        

            
            <?
//NOMBRE DEL ARCHIVO PHP
$pagina = "notas.php";
//NOMBRE DE LA TABLA ADONDE SE QUIERE REALIZAR LA CONSULTA
$tabla = "notas";
//CANTIDAD DE RESULTADOS POR TABLA
$c = 15;

$ID = (int)$_GET['ID'];
$i = $_GET['i'];
$p = $_GET['p'];
if ($i == NULL) {$i = 0; $p = 1;} else {};

include('concha.php');

$sql = "SELECT * FROM $tabla WHERE ver = 'no' ORDER BY ID desc LIMIT $i,$c";
$consulta = $conn->query($sql);
$consulta = $conn->query($sql);
{

$i_d = 0;

$ID = $row["ID"];


$titulo = $row["titulo"];
$fechapub  = $row["fechapub"];
$carpetafoto  = $row["carpetafoto"];
$foto = $row["foto"];
$destacado = $row["destacado"];
$audio = $row["audio"];

$d = $row["d"];
$youtube = $row["youtube"];

$m = $row["m"];

$ver = $row["ver"];
$a = $row["a"];
$color = $row["color"];
$visitas = $row["visitas"];
$impresiones = $row["impresiones"];
$fecha = "$d - $m - $a";

?>
          <?php include 'mostrar_notis.php';?>
<?
 }
$consulta->free_result();

?>

<?php 
$cant = 0;

$sql = "SELECT * FROM $tabla WHERE ver = 'no'";
$consulta = $conn->query($sql);
$consulta = $conn->query($sql);
{
$cant = $cant + 1;
}

$consulta->free_result();

$cant = $cant + $c - 1;
$cant = $cant / $c;
$cant = (int) $cant; //esto es un integer
$pag = 1;
$cuenta = 1;
?>

<div class="col-12">
                  <?php if ($p == 1) {} else { ?>
                  
                  <a class="btn btn-outline-primary" href="<?php echo $pagina ?>?i=<?php echo $i - $c; ?>&amp;p=<?php echo $p - 1; ?>">Anterior</a>
                  
                  <?php }?>
                  -
                  <?php if ($p == $cant) {} else { ?>
                  <a class="btn btn-outline-primary" href="<?php echo $pagina ?>?i=<?php echo $i + $c; ?>&amp;p=<?php echo $p + 1; ?>">Siguiente</a>
                  
                  <?php }?>
                </div>
                
              <br />

              <?
while ($cuenta <= $cant) {
if ($cuenta == $p) {
?>
              <span class="Estilo5 Estilo20"><strong><?php echo $cuenta ?></strong></span><span class="Estilo5"> |</span>
              <?
} else {
?>
              <a href='<?php echo $pagina ?>?i=<?php echo $pag ?>&amp;p=<?php echo $cuenta ?>'> <span class="Estilo5"><?php echo $cuenta ?></span></a><span class="Estilo5"> |</span>
              <?

};

$pag = $pag + $c;
$cuenta++;
}
?>

  
      </div>
</div>

<!-- jQuery first, then Popper.js, then Bootstrap JS -->
<script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.14.7/umd/popper.min.js" integrity="sha384-UO2eT0CpHqdSJQ6hJty5KVphtPhzWj9WO1clHTMGa3JDZwrnQq4sF86dIHNDz0W1" crossorigin="anonymous"></script>
<script src="https://stackpath.bootstrapcdn.com/bootstrap/4.3.1/js/bootstrap.min.js" integrity="sha384-JjSmVgyd0p3pXB1rRibZUAYoIIy6OrQ6VrjIEaFf/nJGzIxFDsf4x0xIM+B07jRM" crossorigin="anonymous"></script>
    
<script src="https://unpkg.com/isotope-layout@3/dist/isotope.pkgd.js"></script>
<script type="text/javascript">

       
           window.setTimeout(function(){
                $('.grid').isotope({
                itemSelector: '.grid-item'
                });
                console.log('qwe');
                }, 3000);
        


        //window.setInterval(function(){
        //$('.grid').isotope({
        //itemSelector: '.grid-item'
        //});
        //}, 4000);

        function ventanaSecundaria56 (URL){
        window.open(URL,"ventana1","width=960,height=630,scrollbars=NO")
        }
        
</script>
 <script defer src="https://use.fontawesome.com/releases/v5.8.1/js/all.js" integrity="sha384-g5uSoOSBd7KkhAMlnQILrecXvzst9TdC09/VM+pjDTCM+1il8RHz5fKANTFFb+gQ" crossorigin="anonymous"></script>   
</body>
</html>
