<?php 
    include 'concha.php';
    include 'concha_extras.php';
    
?>
<!doctype html>
<html lang="es">

<head>
    <!--meta http-equiv="Content-Language" content="en-us">
    <meta name="language" content="es" /-->
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta charset="utf-8" />
    
    <!-- ///version 30.1 -->
    <meta name="viewport" content="width=device-width, initial-scale=1, user-scalable=no">

    <!-- DATOS DEL SITIO META TAGS -->
    <title><?php echo $nombresitio ?></title>
    <meta name="description" content="<?php echo $descripcion_web ?>" />
    <meta name="keywords" content="<?php echo $nombresitio ?>, radio, en vivo, escuchar, portal" />
    <meta name="language" content="es" />

    <!-- TAGS DE FACEBOOK / WHSTSAPP -->
    <meta property="og:title" content="<?php echo $nombresitio ?>" />
    <meta property="og:description" content="<?php echo $descripcion_web ?>" />
    <meta property="og:site_name" content="<?php echo $nombresitio ?>" />

    <meta property="og:type" content="article" />

    
    <meta property="og:url" content="<?php echo $dom ?>" />
    <meta property="og:image" content="<? $logo_C = str_replace('http://', 'https://', $logo_C); echo $logo_C; ?>" />


    <!-- LINKS A GOOGLE FONTS -->
    <? $link_titulo = str_replace('http://', 'https://', $link_titulo);?>
    <?php echo $link_titulo ;?>
    <?$link_menu = str_replace('http://', 'https://', $link_menu);?>
    <?php echo $link_menu; ?>
    <?$link_bajada = str_replace('http://', 'https://', $link_bajada);?>

    <?php echo $link_bajada; ?>


    <? $catba = $_GET['cat'];
$i_publi = 10000000;?>

    <link rel="shortcut icon" href="<?php echo $dom?>/icono.ico" type="image/x-icon" />

    <!-- asd CSS -->


    <!--link href="https://radioshosting.com/css/delalora<? echo $estiloweb ?>new.css" rel="stylesheet"-->

    <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/animate.css/3.7.0/animate.min.css">
    <link rel="stylesheet" href="https://unpkg.com/flickity@2/dist/flickity.min.css" />
    <link href="https://use.fontawesome.com/releases/v5.0.6/css/all.css" rel="stylesheet">
    <link rel="stylesheet" href="https://radioshosting.com/css/css/lightbox.min.css">
    
    <!-- Bootstrap CSS -->
    <link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/4.5.2/css/bootstrap.min.css" integrity="sha384-JcKb8q3iqJ61gNV9KGb8thSsNjpSL0n8PARn9HuZOnIxN0hoP+VmmDGMN5t9UJ0Z" crossorigin="anonymous">
    <link href="https://use.fontawesome.com/releases/v5.0.6/css/all.css" rel="stylesheet">
    
    <!-- Jquery -->
    
    <!--script src="https://code.jquery.com/jquery-3.5.1.slim.min.js" integrity="sha384-DfXdz2htPH0lsSSs5nCTpuj/zy4C+OGpamoFVy38MVBnE+IbbVYUew+OrCXaRkfj" crossorigin="anonymous"></script-->
    
    
<script src="https://code.jquery.com/jquery-3.4.1.min.js"
			  integrity="sha256-CSXorXvZcTkaix6Yvo6HppcZGetbYMGWSFlBw8HfCJo="
			  crossorigin="anonymous"></script>
    
<style>

        body {
            <?php
                $e = substr("$d_color_fondo",0,1);
                $e1 = substr("$d_color_fondo",0,4);

                if ($e == '#') { ?>
                    background-color:<? echo $d_color_fondo ?>;
                    <?

                } else {
                    if ($e1 == 'http') { ?>

                        background-image:url(<? echo $d_color_fondo ?>);
                        background-repeat:repeat;


                        <? } else { ?>

                        background-image: url("https://recursos.radiosnethosting.com/fondos/<? echo $d_color_fondo ?>");
                        background-attachment: fixed;
                        -webkit-background-size: cover;
                        -moz-background-size: cover;
                        -o-background-size: cover;
                        background-size: cover;

                        <? } ?>
                <? } ?>

                overflow-x: hidden;
                margin: 0 auto;

        }


        h1,
        h2,
        h3,
        h4,
        h5,
        h6 {
            margin-bottom: 10px;
            line-height: 1.1em;
            font-weight: 600;
            margin-top: 0;
            color: <?php echo $d_color_titulo?>;
            font-family: <?php echo $style_titulo ?>;
        }

        p {
            font-family: <?php echo $style_bajada ?>;
        }

        .h3,
        h3 {
            font-size: 1rem;
        }

        h1 a,
        h2 a,
        h3 a,
        h4 a,
        h5 a,
        h6 a {
            display: block;
            color: <?php echo $d_color_menu?>;
        }

        a:hover {

            color: <?php echo $d_color_menu_sobre?>;

        }

        a:link,
        a:visited,
        a:active,
        a:focus,
        a:before,
        a:after {
            outline: 0 none;
            text-decoration: none;
            color: <?php echo $d_color_menu?>;
        }





        .navbar-nav .dropdown-menu {
            position: absolute;
            background-color: <? echo $d_color_fondo_menu?>;
        }


        .dropdown:hover>ul {

            display: block !important;

        }

        .dropdown ul li a {

            color: <?php echo $d_color_menu?>;

        }


        .navbar-light .navbar-nav .nav-link:focus,
        .navbar-light .navbar-nav {
            color: <?php echo $d_color_menu ?>;

        }

        .nav-link:hover {
            color: <?php echo $d_color_menu_sobre ?>;

        }

        #logo {
            max-width: 3.2rem;
        }

        #logo:hover path {
            fill: <?php echo $d_color_menu ?>;

        }

        #logo:hover {

            color: <?php echo $d_color_menu_sobre ?>;

        }

        #logo2 {
            fill: <?php echo $d_color_weather2 ?>;
            max-width: 48px;
        }


        #logo3 {
            fill: <?php echo $d_color_weather2 ?>;
            max-width: 18px;
        }

        .color {
            color: <? echo $d_color_menu?>;
        }

        .btn-outline-primary.active,
        .btn-outline-primary:active,
        .show>.btn-outline-primary.dropdown-toggle {
            color: <?php echo $d_color_fondo_menu ?>;
            background-color: <?php echo $d_color_menu ?>;
            border: 3px solid <?php echo $d_color_fondo_menu ?>;
        }

        .btn-outline-primary:hover {
            color: <?php echo $d_color_fondo_menu ?>;
            background-color: <?php echo $d_color_menu ?>;
            border: 3px solid <?php echo $d_color_fondo_menu ?>;

        }

        .btn-outline-primary {
            color: <?php echo $d_color_menu ?>;
            background-color: <?php echo $d_color_fondo_menu ?>;
            border: 3px solid transparent;
        }

        footer p {
            margin-bottom: .25rem;
            color: <?php echo $d_color_menu ?>;
            font-weight: 300;
        }

        .facebook {
            display: block;
            float: right;
            background: <?php echo $d_color_menu ?>;
            margin-right: 37px !important;
        }

        .twitter {
            display: block;
            float: right;
            background: <?php echo $d_color_menu ?>;
        }

        .flickity-page-dots .dot {
            background: <?php echo $d_color_menu ?>;

        }

        .sidebar {
            will-change: min-height;
        }

        .sidebar__inner {
            transform: translate(0, 0);
            /* For browsers don't support translate3d. */
            transform: translate3d(0, 0, 0);
            will-change: position, transform;
        }

        .sidebar .widget .widget-title {
            font-size: 20px;
        }

        <? $hexa=substr($d_color_fondo_menu, 1);

        $decimal=hexdec($hexa);


        if ($decimal <='10066329') {
            $color_titulo_barra="250,250,250,0.9";
        }

        else {
            $color_titulo_barra="0,0,0,0.9";
        }

        ;

        ?>.widget-head {
            /*background-color: <? echo $d_color_fondo_menu?>;*/
        }

        .widget-title {
            font-size: 2rem;
            font-weight: 700;
            line-height: 1;
            margin-bottom: 0;
            color: <?php  echo $d_color_titulo ?>;
            font-family: <?php echo $style_titulo ?>;
        }

        /* ---- grid ---- */



        .topbar {

            border-bottom: 0;

            background-color: <? echo $d_color_fondo_menu ?>;
            color: <? echo $d_color_menu ?>;
        }


        .header {
            min-height: 130px;
            display: flex;
            align-items: center;

            <?php if ($textura==NULL && $logo_g==NULL) {
                ?>background-color: <?php echo $d_color_fondo_cabecera ?>;

                <?
            }

            elseif($textura !=NULL) {
                ?>background-position: center center;
                background-size: cover;
                background-repeat: no-repeat;
                background-image: url(<?php $textura = str_replace("www.radiosnet.com.ar","recursos.radiosnethosting.com",$textura);
                echo $textura ?>);
                -moz-background-size: cover;
                -webkit-background-size: cover;

                <?php
            }

            else {
                ?>background-position: center center;
                background-size: cover;
                background-repeat: no-repeat;
                background-image: url(<?php echo $logo_g ?>);
                -moz-background-size: cover;
                -webkit-background-size: cover;

                <?
            }

            ?>clear: both;


        }


        .header-right {
            float: right;
        }

        .logo {
            max-width: 80%;

        }

        .bg-light {

            background-color: #fff !important;
        }

        article {
            background: transparent;
            /*border-radius: 3px;
                                        border: 1px solid #e4e4e4;*/
        }

        .colorTitulo {
            color: <?php echo $d_color_titulo ?>;
            font-weight: 800;
            letter-spacing: 1px;

        }



        .facebook {

            display: block;
            float: right;
            background-color: <?php echo $color_cat ?> !important;
            margin-right: 37px !important;
        }

        .twitter {

            display: block;
            float: right;
            background-color: <?php echo $color_cat ?> !important;
        }

        p.displaytitulo {
            height: 0;
            margin: 0;
            font-family: 'Montserrat', sans-serif !important;
            letter-spacing: 1px;
        }




        .carousel-caption {

            z-index: 10;
            padding: 4px 20px;
            /* padding-bottom: 20px;
                                position: absolute;
                            right: 0;
                            bottom: 0px;
                            left: 0;
                             */

            background-color: <? echo $d_color_fondo_menu ?>99;

        }

        .carousel-caption h2 {
            color: <? echo $d_color_menu ?> !important;
            font-weight: 700;
            margin: 0;

            font-size: 2.5vw;
        }



        .localidad {
            font-family: <?php echo $style_titulo ?>;
            color: <?php echo $d_color_weather2?>;
            line-height: 1;

        }





        /* destacadas slider */

        .titulo {
            display: none;
            position: absolute;
            bottom: 0;
            height: 100%;
            width: 100%;
            padding: 20px 15px;
            background-color: <?php echo $d_color_fondo_menu ?>;
            opacity: 0.7;
        }


        .cub3r-caption {
            /*display:none;*/
            position: absolute;
            bottom: 0;
            left: 0;
            background-color: <? echo $d_color_fondo_menu?>99;
            width: 100%;
            padding: 0.5rem 0.75rem;
        }

        .cub3r-caption-text {
            color: <? echo $d_color_menu?> !important;
        }

        .html-marquee {
            font-weight: 200;
            height: 40px !important;
            width: 100%;
            background-color: transparent !important;
            font-family: 'Montserrat', sans-serif !important;
            font-size: inherit !important;
            color: <? echo $d_color_menu ?> !important;
            letter-spacing: 0.5px;
        }

        marquee p {
            color: <? echo $d_color_menu ?> !important;
        }

        .texto-fecha {

            color: <? echo $d_color_menu?>;
        }

        .navbar-toggler-icon {
            color: <? echo $d_color_menu?>;
        }
        
        /* Mensajes comentarios */
        
        .mensajesComentarios{
            background-image: url('<?echo $dom?>/assets/mensajesch.jpg');
            background-position: center center;
            background-size: cover;
            min-height:10rem;
            margin-bottom: 15px;
        }
        
        /* Repro en la cabecera */
        
             
                .titoAlgo {
                    width: 250px;
                    height: 250px;
                    background-color:<?php echo $d_color_fondo_menu?>;
                    /*border-radius:50%;*/
                    position:absolute;
                    bottom:-115px;
                    left:calc(50% - 125px);
                    z-index:1001;
                    transform: rotate(45deg);
                }
                
                .titoAlgo div {
                    /*padding-top:5px;*/
                }
                
                .titoAlgo1:before {
                    content: '';
                    width: 400px;
                    height: 400px;
                    background-color: <?php echo $d_color_menu?>;
                    z-index: 1000;
                    position: absolute;
                    bottom: -192px;
                    /*border-radius: 50%;*/
                    left: calc(50% - 200px);
                    transform: rotate(45deg);
                }
                
                .botonReproNuevo {
                    color:<?php echo $d_color_menu ?>;
                    transform: rotate(-45deg);
                }
                
                i{
                    cursor:pointer;
                }
                
                .listaRedes{
                    list-style:none;
                    position:absolute;
                    top:calc(50% - 100px);
                    right:15px;
                    background:<? echo $d_color_fondo_menu ?>;
                }


        @media (min-width: 576px) { 
            
                .titoAlgo {
                    width: 500px;
                    height:500px;
                    background-color:<?php echo $d_color_fondo_menu?>;
                    /*border-radius:50%;*/
                    position:absolute;
                    bottom:-360px!important;
                    left:calc(50% - 250px);!important
                    z-index:1001;
                }
                
                .titoAlgo1:before {
                    content: '';
                    width: 800px;
                    height: 800px;
                    background-color: <?php echo $d_color_menu?>;
                    z-index: 1000;
                    position: absolute;
                    bottom: -550px;
                    /*border-radius: 50%;*/
                    left: calc(50% - 400px);
                }
            
            .grido {
                column-count: 1;
            }
        }
        

        @media (min-width: 768px) { 
            
            .grido {
                column-count: 1;
            }
        }
        

        @media (min-width: 992px) { 
            
            .grido {
                column-count: 1;
            }
        }


        @media (min-width: 1200px) { 
            
            .grido {
                column-count: 1;
            }
        }

  
         
        /* Small devices (landscape phones, 576px and up) */
        @media (min-width: 576px) {
            .listaPublis {
            column-count: 1;
              }
        }
         
        /* Medium devices (tablets, 768px and up) The navbar toggle appears at this breakpoint */
        @media (min-width: 768px) {  
            .listaPublis {
            column-count: 2;
              }
        }
         
        /* Large devices (desktops, 992px and up) */
        @media (min-width: 992px) { 
            .listaPublis {
            column-count: 3;
           }
        }
        
        .section{
            /*min-height: 100vh;
            display: grid;*/
        }
  
</style>
</head>


<body>
    
    <!-- Menu cabecera -->
    
    <section class="container-fluid p-0">
        
        <?php include 'menu_estilo9.php';?>
        
        <!-- Comienza resultados de las disciplinas-->


            <?php
                $hay_cuber_0 = 'no';
                mysql_connect ("$host", "$usuario", "$contra");
                mysql_select_db ("$basedatos");
                $sql = "SELECT * FROM notas_tapa WHERE cu3er = '0' ORDER BY ID desc";
                $consulta = mysql_query ($sql);
                while ($row = mysql_fetch_array($consulta))
                {
                    $ID_notaaa = $row["ID"];
                    $hay_cuber_0 = 'si';
                } mysql_free_result($consulta);
            
            
                mysql_connect ("$host", "$usuario", "$contra");
                mysql_select_db ("$basedatos");
                $sql = "SELECT * FROM notas_tapa WHERE cu3er = '0' ORDER BY ID desc LIMIT 1";
                $consulta = mysql_query ($sql);
                while ($row = mysql_fetch_array($consulta))
                {
                $ID_nota = $row["ID"];
                $foto = $row["foto"];
                $ext_img = $row["ext_img"];
                $titulo = $row["titulo"];
                $texto = $row["texto"];
                $nota = $row["nota"];
                $etiqueta2 = $row["etiqueta"];
                $can = $can + 1

            ?>
            <style>
                .nuevaCabecera {
                    background: url('<? echo $dom ?>/upload_pic/resize_<?php echo $foto ?>.jpg');
                    background-repeat:no-repeat;
                    min-height: 100vh;
                    background-position:center center;
                    background-size: cover;
                    overflow:hidden;
                    position:relative;
                    background-attachment: fixed;
                }    
            </style>

                <div class="nuevaCabecera">
                    
                    <div class="col-8 offset-2 text-center">
                        <img src="<? $logo_C = str_replace('http://', 'https://', $logo_C);
                                     echo $logo_C; ?>"
                             class="img-fluid"
                             alt="<?php echo $nombresitio ?>" 
                             title="<?php echo $nombresitio ?>"
                             >
                    </div>
                    
                    <ul class="mb-0 p-0 listaRedes">

                                        <li class="text-center d-none">

                                                <a href="#" role="button" id="dropdownMenuLink" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false" class="btn btn-block">
                                                    <i class="fas fa-search fa-1x" style="color: <? echo $d_color_menu?>;"></i>
                                                </a>
                                                <div class="dropdown-menu menuBusqueda" aria-labelledby="dropdownMenuLink">
                                                    <form id="form1" name="form1" method="GET" action="buscar.php">
                                                        <input name="busqueda" type="text" class="form-control" size="30" value="" id="inputString" onkeyup="lookup(this.value);" onblur="fill();" />
                                                        <input name="Submit" type="submit" class="btn btn-outline-primary my-2 my-sm-0" value="<? echo $lang_buscar ?>" />
                                                    </form>

                                                </div>

                                        </li>
                                        

                                        <?php  if ($whatsapp == NULL) {} else {?>

                                            <li class="text-center">

                                                <a class="btn btn-block" target="_blank" href="https://api.whatsapp.com/send?phone=<?php echo $whatsapp ?>">
                                                    <i class="fab fa-whatsapp fa-1x" aria-hidden="true"  style=" color: <? echo $d_color_menu?>;"></i></a>

                                            </li>

                                        <?php };?>

                                        <?php if ($facebook == NULL) {} else {?>
                                            <li class="text-center">
                                                <a class="btn btn-block" target="_blank" href="<?php echo $facebook ?>">
                                                    <i class="fab fa-facebook fa-1x" aria-hidden="true" style=" color: <? echo $d_color_menu?>;"></i></a>
                                            </li>
                                        <?php };?>



                                        <?php if ($social_aim == NULL) {} else {?>
                                            <li class="text-center">
                                                <a class="btn btn-block" target="_blank" href="<?php echo "https://instagram.com/".$social_aim ?>">
                                                    <i class="fab fa-instagram fa-1x" aria-hidden="true" style=" color: <? echo $d_color_menu?>;"></i></a>
                                            </li>
                                        <?php };?>

                                        <?php if ($twitter_btn == NULL) {} else {?>
                                        <li class="text-center">
                                            <a class="btn btn-block" target="_blank" href="<?php echo $twitter_btn ?>">
                                                <i class="fab fa-twitter fa-1x" style=" color: <? echo $d_color_menu?>;"></i></a>
                                        </li>
                                        <?php };?>

                                        <?php if ($social_blogger == NULL) {} else {?>
                                        <li class="text-center">
                                            <a class="btn btn-block" target="_blank" href="<?php echo $social_blogger ?>">
                                                <i class="fab fa-blogger fa-1x" style=" color: <? echo $d_color_menu?>;"></i></a>
                                        </li>
                                        <?php };?>

                                        <?php if ($social_flickr == NULL) {} else {?>
                                        <li class="text-center">
                                            <a class="btn btn-block" target="_blank" href="<?php echo $social_flickr ?>">
                                                <i class="fab fa-flickr fa-1x" style=" color: <? echo $d_color_menu?>;"></i></a>
                                        </li>
                                        <?php };?>

                                        <?php if ($social_google == NULL) {} else {?>
                                        <li class="text-center">
                                            <a class="btn btn-block" target="_blank" href="<?php echo $social_google ?>">
                                                <i class="fab fa-google fa-1x" style=" color: <? echo $d_color_menu?>;"></i></a>
                                        </li>
                                        <?php };?>

                                        <?php  if ($social_tumblr == NULL) {} else {?>
                                        <li class="text-center">
                                            <a class="btn btn-block" target="_blank" href="<?php echo $social_tumblr ?>">
                                                <i class="fab fa-instagram fa-1x" style=" color: <? echo $d_color_menu?>;"></i></a>
                                        </li>
                                        <?php };?>

                                        <?php if ($social_vimeo == NULL) {} else {?>
                                        <li class="text-center">
                                            <a class="btn btn-block" target="_blank" href="<?php echo $social_vimeo ?>">
                                                <i class="fab fa-vimeo-v fa-1x" style=" color: <? echo $d_color_menu?>;"></i></a>
                                        </li>
                                        <?php };?>

                                        <?php if ($social_yahoo == NULL) {} else {?>
                                        <li class="text-center" >
                                            <a class="btn btn-block" target="_blank" href="<?php echo $social_yahoo ?>">
                                                <i class="fab fa-yahoo fa-1x" style=" color: <? echo $d_color_menu?>;"></i></a>
                                        </li>
                                        <?php };?>

                                        <?php  if ($social_youtube == NULL) {} else {?>
                                        <li class="text-center" >
                                            <a  class="btn btn-block" target="_blank" href="<?php echo $social_youtube ?>">
                                                <i class="fab fa-youtube fa-1x" style=" color: <? echo $d_color_menu?>;"></i></a>
                                        </li>
                                        <?php };?>

                                        <?php // include 'weather_magazine2.php';?>
                                        
                                        <?php if ($funcion1 == 'si'){ ?>

                                            <li class="mt-3">

                                                <a class="p-2" style="background: red"  target="_blank" href="<?php echo $dom."/envivo"?>"><small style="color: white;">EN VIVO</small></a>

                                            </li>

                                        <?php } else { } ?>


                            </ul>
                            
                    <div class="titoAlgo d-flex justify-content-center">
                        <div class="col-12 text-center botonReproNuevo">
                            <div align="">
        
                                        <div style="text-align:center;">
                                        
                                          <audio id="player" src="<?php echo $ip_stream ?>;stream.mp3" type="audio/mp3" ontimeupdate="updateProgress();" autoplay >
                                              <source  id="source">	
		                                        Audio no soportado	
                                          </audio>
                                        </div>
                                        
        
                                  <?php
                                  
                                    $port1 = substr($ip_stream,19);
        
                                    
                                    ?>
        

	
	                                <div id="controls" class="">
                                		<div class="timer d-none" id="timer"></div>
                                		<div class="d-none volumen  justify-content-center align-items-center">
                                			
                                			<i class="fas fa-volume-down p-2"></i> 
                                			<input type="range" name="volumen" id="volumen" min="0" max="1" step="0.01" value="0.75"> 
                                			<i class="fas fa-volume-up p-2"></i>
                                		</div>
                                		
                                		<i class="d-none fas fa-backward fa-3x" onclick="prevMusic();"></i>
                                		<i class="fas fa-play fa-2x" onclick="togglePlay();" id="iconPlay"></i> 
                                		<i class="d-none fas fa-forward fa-5x" onclick="nextMusic();"></i>
                                		
                                		<span id="currentPlay" class="d-none"></span>
                                		<progress class="d-none" id="progress" value="0" max="100" ></progress>
                                		
                                
                                		<div id="playList" class="d-none"></div>
                                 
                                	</div>
        
                                </div>
                                
                                <div class="row mt-3 d-none">
                    
                                <?php
                                    
                                    $hay_programa = 'no';
                                    
                                    $hora = date(H);
                                    $min = date(i);
                                    $hora = "$hora.$min";
                                    mysql_connect ("$host", "$usuario", "$contra");
                                    mysql_select_db ("$basedatos");
                                    $sql = "SELECT * FROM programacion WHERE dia = '$dia'";
                                    $consulta = mysql_query ($sql);
                                    
                                    while ($row = mysql_fetch_array($consulta)) {
                                        
                                        $programa= $row["programa"];
                                        $ini = $row["ini"];
                                        $fin = $row["fin"];
                                        $ini = str_replace(".","",$ini);
                                        $fin = str_replace(".","",$fin);
                                        $hora = str_replace(".","",$hora);
                                        $ini =  (int) $ini;
                                        $fin = (int) $fin;
                                        $hora = (int) $hora;
                                            
                                        if ($hora > $ini) {
                                        
                                            if ($hora < $fin) { 
                                                
                                                $ID_P = $programa; 
                                                $ini2 = $row["ini"];
                                                $fin2 = $row["fin"];
                                                
                                            }
                                        
                                        } else {};
                                        
                                        $sql2 = "SELECT * FROM programas WHERE ID = '$ID_P'";
                                        $consulta2 = mysql_query ($sql2);
                                        
                                        while ($row2 = mysql_fetch_array($consulta2)) {
                                            
                                            $nombre_pro = $row2["nombre"];
                                            $imagen = $row2["imagen"];
                                            $url = $row2["url"];
                                            $hay_programa = 'si';
                        
                                        }
                                        
                                        mysql_free_result($consulta2);
                                    
                                    }
                                    
                                    mysql_free_result($consulta);
                                    
                
                                    if ($hay_programa == 'no') { ?>
                                    
                                        
                                                <div class="col-4 p-0 text-right d-none">
                                                    <img class="cc_streaminfo" data-type="trackimageurl" data-username="planetacabezon" width="60px" />
                                                </div>
                                                <div class="col-8 text-left d-none">
                                                    <b><span id="cc_strinfo_tracktitle_planetacabezon" class="cc_streaminfo" >Cargando</span></b><br>
                                                    <span id="cc_strinfo_trackartist_planetacabezon" class="cc_streaminfo"></span>
                                                </div>
                                            
                                            
                                        
                                        
                                    <? } else { 
                                        
                                        if ($imagen == '') { ?>
                        
                                            <div class="col-4 text-right p-0">
                                                
                                                <img src="<? echo $logo_C;?>" class="img-fluid" style="max-width:48px;background: white;">
                        
                                            </div>
                        
                    
                                    <?php 
                                    
                                        } else { ?>
                        
                                            <div class="col-4 text-right p-0">
                                                
                                                <img src="<? echo $dom;?>/upload_pic/resize_<?php echo $imagen ?>.jpg" class="img-fluid" style="max-width:48px;background: white;">
                        
                                            </div>
                        
                    
                                <?php } ?>
                        
                                            <div class="col-8 text-left">
                                                
                                                <p class="m-0 textSmall"><?php echo $nombre_pro ?></p>
                                                <p class="m-0 textSmall"><small><?php echo  $ini2 ?>hs. a <?php echo $fin2 ?>hs.</small></p>
                        
                                            </div>
                                            
                                <? } ?>
                                    
                                </div>

                            
                        </div>
                        
                    </div>
                    <div class="titoAlgo1"></div>
                    
                    
                </div>

            <?
                } mysql_free_result($consulta);
            ?>



            <!-- radio en vivo banner-->
    </section>
    
    <!-- Menu cabecera -->
    
    
    <!-- Programacion -->

    <section class="section py-5 container">
            
            <div class="widget-head text-center col-12 mb-3" style="">
                
                  <h3 class="widget-title py-5">
                    <span>Programación</span>
                  </h3>
               
            </div>
              
            <div class="col-12">

              <div class="table-responsive">
                <table class="table">
                    
                    <thead>

                      <tr>
                        <th scope="col"><strong>Lunes</strong></th>
                        <th scope="col"><strong>Martes</strong></th>
                        <th scope="col"><strong>Miercoles</strong></th>
                        <th scope="col"><strong>Jueves</strong></th>
                        <th scope="col"><strong>Viernes</strong></th>
                        <th scope="col"><strong>Sábado</strong></th>
                        <th scope="col"><strong>Domingo</strong></th>
                      </tr>
                    </thead>
                    <td valign="top">
                        <?php 
                        $dia = "Lunes";  
                        include 'select_programacion.php';
                        ?>
                    </td>
                    <td valign="top">
                        <?php 
                        $dia = "Martes"; 
                        include 'select_programacion.php';
                        ?>
                    </td>
                    <td valign="top">
                        <?php 
                        $dia = "Miercoles";  
                        include 'select_programacion.php';
                        ?>
                    </td>
                    <td valign="top">
                        <?php 
                        $dia = "Jueves"; 
                        include 'select_programacion.php';
                        ?>
                    </td>
                    <td valign="top">
                        <?php 
                        $dia = "Viernes";
                        include 'select_programacion.php';
                        ?>
                    </td>
                    <td valign="top">
                        <?php 
                        $dia = "Sabado"; 
                        include 'select_programacion.php';
                        ?>
                    </td>
                    <td valign="top">
                        <?php 
                        $dia = "Domingo";
                        include 'select_programacion.php';
                        ?>
                    </td>
                 
                </table>
              </div>

        </div>
    </section>
    
    <!-- Programacion -->
    
    
    <!-- Publis -->

    <section class="section py-5 container">
            
            <div class="widget-head text-center col-12 mb-3" style="">
                
                  <h3 class="widget-title py-5">
                    <span>Publicidades y patrocinios</span>
                  </h3>
               
            </div>
              
            <div class="col-12">
                
                    <div class="listaPublis">
                    
    
                            <?php 
                                mysql_connect ("$host", "$usuario", "$contra");
                                mysql_select_db ("$basedatos");
                                $sql = "SELECT * FROM `publicidades_gif` WHERE lugar = 999 ORDER BY ID";
                                $consulta = mysql_query ($sql);
                                while ($row = mysql_fetch_array($consulta))
                                {
                                	$ID_publi = $row["ID"];
                                	$carpetafoto = $row["carpetafoto"];
                                	$img_publi = $row["img"];
                                	$url_publi = $row["url"];
                                	?>
                                <div class="col-12 text-center p-0">
                                    <a class="btn" href="<?php echo $url_publi ?>" target="_blank">
                                        <img src="<?php echo $dom."/".$carpetafoto."/".$img_publi ?>" class="img-fluid bg-light" />
                                    </a>
                                </div>
                                
                            <?php } mysql_free_result($consulta);?>
    
                        
                    </div>
            </div>
    </section>
    
    <!-- Publis -->
    
    <!-- Mensajes comentarios -->
    
    <section class="section container py-5">
        
        <div class="widget-head text-center col-12 mb-3" style="">
            
            <h3 class="widget-title py-5">
                <span>Comentarios</span>
            </h3>
               
        </div>
        
        <div class="container">
            <div class="row pt-4">
            
            <div class="col-12 text-center">
                <img class="d-none img-fluid" src="<?php $logo_C = str_replace('http://', 'https://', $logo_C); echo $logo_C; ?>" style="max-width: 300px;"  alt="Logo"> 
            </div>
            
            <div class="container mt-3">
                <div class="row">
                    <div class="col-12 col-sm-7 mensajesComentarios">

                    </div>
                    <div class="col-12 col-sm-5 text-center">
                        <iframe  src="envivo/chat.php" style="width:100%;height:60vh;border:none;"></iframe>    
                    </div>
                </div>
            </div>
            
        </div>
        </div>
        
    </section>
    
    <!-- Mensajes comentarios -->
    
    <!-- Redes -->
    
    <? 
    if ($social_aim == ' ' && $facebook == ' ' && $twitter == ' ') {  } else { ?>
        
        <section id="main-content" class="section container-fluid p-0">
        
            <?php include 'footer_estilo9.php';?>
        
        </section>
        
    <? }
    ?>
    
    
    <!-- Redes -->
    
    <!-- Footer -->
    
    <section class="container-fluid py-5 border-top" style="background:<?php echo $d_color_fondo_menu?>;">
        <div class="container">
           <div class="row">
              <div class="col-md-6">
                 <div class="row">
                    <div class="col-md-6 ">
                       <div class="logo-part">
                          <img class="img-fluid w-50" src="<?php $logo_C = str_replace('http://', 'https://', $logo_C); echo $logo_C; ?>" style="max-width: 300px;"  alt="Logo"> 
                       </div>
                        
                    </div>
                    <div class="col-md-6 px-4">
                        <h6 style="color:<? echo $d_color_menu?>;">Nosotros</h6>
                       <div><?php echo "<p style='color:".$d_color_menu."'>".$contacto."</p>" ?></div>
                    </div>
                 </div>
              </div>
              <div class="col-md-6">
                 <div class="row">
                    <div class="col-12 ">
                        <h6 style="color:<? echo $d_color_menu?>;">Newsletter</h6>
                        <div class="social">
                        
                            <?php  if ($whatsapp == NULL) {} else {?>
                            
                              <a class="text-center"target="_blank" href="<?php echo $whatsapp ?>">
                                <i class="fab fa-whatsapp" aria-hidden="true"></i>
                              </a>
                            
                            <?php };?>
                            <?php  if ($facebook == NULL) {} else {?>
                            
                              <a class="text-center"target="_blank" href="<?php echo $facebook ?>">
                                <i class="fab fa-facebook" aria-hidden="true"></i>
                              </a>
                           
                            <?php };?>
                            <?php  if ($twitter_btn == NULL) {} else {?>
                            
                              <a class="text-center"target="_blank" href="<?php echo $twitter_btn ?>">
                                <i class="fab fa-twitter" aria-hidden="true"></i>
                            </a>
                            <?php };?>
                            <?php  if ($social_aim == NULL) {} else {?>
                            
                              <a class="instagram" target="_blank" href="<?php echo "https://instagram.com/".$social_aim ?>">
                                <i class="fab fa-instagram" aria-hidden="true"></i>
                              </a>
                            
                            <?php };?>
                            <?php  if ($social_blogger == NULL) {} else {?>
                            
                              <a class="text-center"target="_blank" href="<?php echo $social_blogger ?>">
                                <i class="fab fa-blogger" aria-hidden="true"></i>
                              </a>
                          
                            <?php };?>
                            <?php  if ($social_flickr == NULL) {} else {?>
                            
                              <a class="text-center"target="_blank" href="<?php echo $social_flickr ?>">
                               <i class="fab fa-flickr" aria-hidden="true"></i>
                              </a>
                         
                            <?php };?>
                            <?php  if ($social_google == NULL) {} else {?>
                            
                              <a class="text-center"target="_blank" href="<?php echo $social_google ?>">
                                <i class="fab fa-google" aria-hidden="true"></i>
                              </a>
                          
                            <?php };?>
                
                            <?php  if ($social_tumblr == NULL) {} else {?>
                            
                              <a class="text-center"target="_blank" href="<?php echo $social_tumblr ?>">
                                <i class="fab fa-tumblr" aria-hidden="true"></i>
                              </a>
                          
                            <?php };?>
                            <?php  if ($social_vimeo == NULL) {} else {?>
                          
                              <a class="text-center"target="_blank" href="<?php echo $social_vimeo ?>">
                                <i class="fab fa-vimeo-v" aria-hidden="true"></i>
                              </a>
                           
                            <?php };?>
                            <?php  if ($social_yahoo == NULL) {} else {?>
                          
                              <a class="text-center"target="_blank" href="<?php echo $social_yahoo ?>">
                                <i class="fab fa-yahoo" aria-hidden="true"></i>
                              </a>
                          
                            <?php };?>
                            <?php  if ($social_youtube == NULL) {} else {?>
                           
                              <a class="text-center"target="_blank" href="<?php echo $social_youtube ?>">
                                <i class="fab fa-youtube" aria-hidden="true"></i>
                              </a>
                            
                            <?php };?>

          
                        </div>
                        <form class="form-footer my-3">
                            <div class="form-group">
                                
                            <input class="form-control" type="text"  placeholder="newsletter" name="search">
                            <input class="btn btn-outline-primary" type="button" value="Enviar" >
                            </div>
                        </form>
                        </div>
                       <p></p>
                    </div>
                 </div>
              </div>
           </div>
        </div>
    </section>
    
    <!-- Footer -->
               
    <?php include 'clix_footer.php';?>     

<script src="https://cdn.jsdelivr.net/npm/popper.js@1.16.1/dist/umd/popper.min.js" integrity="sha384-9/reFTGAW83EW2RDu2S0VKaIzap3H66lZH81PoYlFhbGU+6BZp6G7niu735Sk7lN" crossorigin="anonymous"></script>
<script src="https://stackpath.bootstrapcdn.com/bootstrap/4.5.2/js/bootstrap.min.js" integrity="sha384-B4gt1jrGC7Jh4AgTPSdUtOBvfO8shuf57BaghqFfPlYxofvL8/KUEfYiJOMMV+rV" crossorigin="anonymous"></script>

<script>

window.addEventListener("load", function(event) {
    
    let audioTag = document.querySelector('audio');
    
    audioTag.addEventListener('canplay', (event) => {
      console.log('Yay! The readyState just increased to  ' +
          'HAVE_CURRENT_DATA or greater for the first time.');
    });
    
    if (audioTag.paused == false) {
        toggleIcon();
    }
    
    if (!audioTag.duration){
        
        console.log(audioTag.duration)
        var element = document.getElementById("iconPlay")
	    element.classList.remove("fa-play");
    }
  });

 
//Array con el listado de canciones a mostrar en el reprodutor
const canciones = [
"bensound-summer.mp3"
]

var indiceActual = new Array(1);

//Funcion para crear mediante javascript el listado de canciones
function crearPlayList(){
	const listado = document.createElement('ol')
	listado.setAttribute("id", 'listadoMusica')
	for (let i = 0; i<canciones.length; i++){
		const item = document.createElement('li')
		item.appendChild(document.createTextNode(canciones[i])) 
		item.setAttribute("id", canciones.indexOf(canciones[i]))
		listado.appendChild(item)
	}
	return listado
}
document.getElementById('playList').appendChild(crearPlayList())
 
var listadoMusica= document.getElementById('listadoMusica');

listadoMusica.onclick = (e) =>{
	const itemClick = e.target
	removeActive()
	itemClick.classList.add("active");
	reproduccionActual("Reproduciendo: "+ itemClick.innerText)
	loadMusic(itemClick.innerText)
	player.play()
	indiceActual[0]= e.target.id
	classIconPlay();
 
}

//Funcion para cambiar el icono del reprodutor
function classIconPlay(){
	var element = document.getElementById("iconPlay")
	element.classList.remove("fa-pause");
    element.classList.add("fa-play");
}

//Funcion para control del volumen
const volumen= document.getElementById("volumen")
volumen.oninput= (e) =>{
	const vol = e.target.value
	player.volume = vol;
}

//Funcion para actualizar la barra de progreso del reprodutor
const updateProgress = () =>{
	if (player.currentTime >0){
		const barra = document.getElementById('progress')
		barra.value = (player.currentTime / player.duration) * 100
		
		var duracionSegundos= player.duration.toFixed(0);
		dura=secondsToString(duracionSegundos);
		var actualSegundos = player.currentTime.toFixed(0)
		actual=secondsToString(actualSegundos);
		
		duracion= actual +' / '+ dura
		document.getElementById('timer').innerText=duracion 
	}
	if (player.ended){
		nextMusic();//Reproducir la siguiente pista
	} 
}

//Funcion para reproducir la proxima cancion
function nextMusic(){  
	const source = document.getElementById('source');
	var musicaActual= Number(indiceActual[0]);
	if (canciones.length == (musicaActual+1)){
		var siguiente = 0
	} else {
		var siguiente = musicaActual + 1
	}
	removeActive()
	var item=document.getElementById(siguiente)
	item.classList.add("active");
	loadMusic(canciones[siguiente]);
	player.play()
	indiceActual[0]= siguiente
	reproduccionActual("Reproduciendo: "+ canciones[siguiente])
	classIconPlay()
}

//Funcion para reproducir la cancion anterior
function prevMusic(){  
	const source = document.getElementById('source');
	var musicaActual= Number(indiceActual[0]);
	if (musicaActual==0){
		var anterior= canciones.length - 1
	} else {
		var anterior = musicaActual - 1
	}
	removeActive()
	var item=document.getElementById(anterior)
	item.classList.add("active");
	loadMusic(canciones[anterior]);
	player.play()
	indiceActual[0]= anterior
	reproduccionActual("Reproduciendo: "+ canciones[anterior])
	classIconPlay()
}

//Funcion para remover todas las clases css activas
function removeActive(){
	var elems = document.querySelectorAll(".active");
 	 [].forEach.call(elems, function(el) {
    	el.classList.remove("active");
 	 });
 	 return elems
}

//Funcion para mostrar el nombre del arhivo actual en reproduccion
function reproduccionActual(texto){
	document.getElementById('currentPlay').innerText=texto
}

//Funcion para cargar las canciones en el reproductor
function loadMusic(ruta){
	var source = document.getElementById('source')
	var folder ="audio";//Carpeta donde tenemos almancenada la musica
	source.src= folder+"/"+ruta
	var index= indiceActual[0]= canciones.indexOf(ruta);
	console.log(index);
	removeActive();
	var item=document.getElementById(index)
	item.classList.add("active");
	reproduccionActual("Reproduciendo: "+ ruta)
	player.load()
}

//Funcion para pausar o darle play 
function togglePlay() {
	if (player.paused){
		toggleIcon();
		return player.play();
	} else {
		toggleIcon();
		return player.pause();
	}
}

//Funcion para cambiar el icono play o pause
function toggleIcon() {
   var element = document.getElementById("iconPlay");
   element.classList.toggle("fa-pause");
   element.classList.toggle("fa-play");
}

//Funcion para que al dar click sobre la barra de progeso se permita adelantar
progress.addEventListener('click', adelantar);
function adelantar(e){
	const scrubTime = (e.offsetX / progress.offsetWidth) * player.duration;
	player.currentTime = scrubTime;
	sonsole.log(e);
}

//Funcion para convertir segundos a minutos y horas
function secondsToString(seconds) {
	var hour="";
	if (seconds>3600){
		hour = Math.floor(seconds / 3600);
		hour = (hour < 10)? '0' + hour : hour;
		hour+=":"
	}
   var minute = Math.floor((seconds / 60) % 60);
  minute = (minute < 10)? '0' + minute : minute;
  var second = seconds % 60;
  second = (second < 10)? '0' + second : second;
  return hour  + minute + ':' + second;
}

loadMusic(canciones[0])

</script>
<script language="javascript" type="text/javascript" src="https://centova.radiosnethosting.com:2199/system/streaminfo.js"></script>
<script language="javascript">

    (function(){ 
        
        var centovacast = (window.centovacast||(window.centovacast={}));
        
        (centovacast.streaminfo || (centovacast.streaminfo={})).config = {
        
            poll_limit: 120,        // specify how many times to poll the server
            poll_frequency: 15000  // specify the poll frequency in milliseconds
        
        };
        
    })();
    
</script>
</body>
</html>