<?php include 'sesion.php';?>
<?php include 'concha.php';?>
<!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-image: url(../fondeux.jpg);
            background-position:top center;
            background-repeat: repeat-x;
            background-color:#EBEBEB;
            height:100%;
        }

        .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 include 'menu.php';  ?>
     
    
    
</div>

<div role="main" style="background-color:#fff;" class="container pt-3">
    
    <div class="page-header" style="text-align:center;">
        <h2><? echo $asd ?>Editores</h2>
    </div>
    
    <div class="col-12 my-3">
        <div class="col-12 my-3">

            <p>CARGAR UN EDITOR NUEVO</p>
            <p>El editor no otorga acceso al panel solo permite mostrar al autor de la nota.</p>
            <p><b>Importante</b> todos los datos que ingrese se mostrarán en la web, si no desea incluir algún dato sobre el editor simplemente deje el campo vacío.</p>
            
            <form id="form2" name="form2" method="post" action="form_cargar_editor.php">
    
                <div class="form-group">
                    <label>Nombre</label>
                    <input type="text" name="nombre" id="nombre" class="form-control"/>
                </div>
    
                <div class="form-group">
                    <label>Telefono</label>
                    <input type="text" name="telefono" id="telefono" class="form-control"/>
                </div>
                    
                <div class="form-group">
                    <label>E-mail</label>
                    <input type="text" name="email" id="email" class="form-control"/>
                </div>
                      
                <div class="form-group">
                    <label>Facebook</label>
                    <input type="text" name="facebook" id="facebook" class="form-control"/>
                </div>      
                
                <div class="form-group">
                    <label>Twitter</label>
                    <input type="text" name="twitter" id="twitter" class="form-control"/>
                </div>      
                
                <div class="form-group">
                    <label>Instagram</label>
                    <input type="text" name="instagram" id="instagram" class="form-control"/>
                </div>      
                
                <div class="form-group my-3">
                    <button type="submit" class="btn btn-block btn-outline-primary" name="button" id="button">Cargar</button>
                </div>
    
            </form>

        </div>
        
        <div class="col-12 my-3">

            <h3>Editores cargados</h3>
            
            <div class="container">
                <?php 
                   
                    $sql65 = "SELECT * FROM editores ORDER BY nombre";
                    $consulta65 = $conn->query($sql);
                    while ($row65 = $consulta65->fetch_assoc())
                    {
                    $nombre = $row65["nombre"];
                    $telefono = $row65["telefono"];
                    $email = $row65["email"];
                    $instagram = $row65["instagram"];
                    $facebook = $row65["facebook"];
                    $twitter = $row65["twitter"];
                    $foto = $row65["foto"];
                    $ID_editor = $row65["ID"];
                ?>
                <div class="row border-bottom p-3 mb-3">
                    <div class="col-4 p-0">
                        <img src="<?php echo $foto ?>"  class="img-fluid"/>
                    </div>
                    <div class="col-8">
                        <h4><?php echo $nombre;?></h4>
                        <?php 
                            if($foto) {?>
                                <a class="btn btn-outline-primary mb-3" href="../subir_foto_editor.php?ID=<?php echo $ID_editor ?>">Editar foto</a>
                            <?} else {?>
                                <a class="btn btn-outline-primary mb-3" href="../subir_foto_editor.php?ID=<?php echo $ID_editor ?>">Cargar foto</a>
                            <?}
                        ?>
                        <a class="btn btn-danger mb-3" href="./form_eliminar_editor.php?ID=<?php echo $ID_editor ?>">Borrar</a>
                    </div>

                    
                </div>
                
                <?} $consulta65->free_result(); ?>
                
            </div>
    
        </div>
    </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>


