<?php
include 'url_amigable.php';
include 'concha.php';

if ($lang_actual == 'es' or $lang_actual == '')
{
include 'lang_es_no_panel.php';
};

 if ($lang_actual == 'pt')
{
include 'langes_pt_no_panel.php';
};

$ID = (int)$_GET['ID'];

$ID_NOTA = "$ID";

if ($ID == '') {exit;};

$sql = "SELECT * FROM notas WHERE ID = '$ID' LIMIT 1";

$consulta = mysql_query ($sql);

while ($row = mysql_fetch_array($consulta))

{

$ID = $row["ID"];
$ID_NOTA = $row["ID"];
$carpetafoto = $row["carpetafoto"];
$foto = $row["foto"]; $ext_img = $row["ext_img"];
$cat_no = $row["cat"];
$titulo = $row["titulo"];
$texto = $row["texto"];
$texto = str_replace('<div','<span',$texto);
$texto = str_replace('</div>','</span>',$texto);
$bajada = $row["bajada"];
$audio = $row["audio"];
$d = $row["d"];
$m = $row["m"];
$m2 = $row["m"];
$a = $row["a"];
$tag1 = $row["tag1"];
$tag2 = $row["tag2"];
$tag3 = $row["tag3"];
$tag4 = $row["tag4"];
$tag5 = $row["tag5"];
$youtube = $row["youtube"];
$visitas = $row["visitas"];
$html = $row["html"];
$ext_img = $row["ext_img"];
$ID_editor = $row["editor"];
$pie_foto = $row["pie_foto"];

$ejemplo_marca_de_agua = $row["ejemplo_marca_de_agua"];
}

mysql_free_result($consulta);


$esta_rel_cargado = 0;
$sql = "SELECT * FROM `referencias_nota` WHERE `ID_nota` = '$ID_NOTA' LIMIT 1";

$consulta = mysql_query ($sql);

while ($row = mysql_fetch_array($consulta))

{
$esta_rel_cargado = 1;
$ref_audio 	 = $row["audio"];
$ref_fotos_notas  = $row["fotos_notas"];
$ref_fotosnotasfull  = $row["fotosnotasfull"];
$ref_tiene_publi_gif  = $row["tiene_publi_gif"];
$ref_rotativas  = $row["rotativas"];
$ref_videos 	 = $row["videos"];
$ref_archivos  = $row["archivos"];
$ref_comentarios  = $row["comentarios"];
$ref_opcion_extra_1 	 = $row["opcion_extra_1"];
$ref_opcion_extra_2  = $row["opcion_extra_2"];

}

mysql_free_result($consulta);

if ($esta_rel_cargado == 0) {

  $ref_audio 	 = 1;
  $ref_fotos_notas  = 1;
  $ref_fotosnotasfull  = 1;
  $ref_tiene_publi_gif  = 1;
  $ref_rotativas  = 1;
  $ref_videos 	 = 1;
  $ref_archivos  = 1;
  $ref_comentarios  = 1;
  $ref_opcion_extra_1 	 = 1;
  $ref_opcion_extra_2  = 1;

};



$visitas = $visitas + 1;

$sSQL="UPDATE  `$basedatos`.`notas` SET  `visitas` =  '$visitas' WHERE ID = '$ID_NOTA'";

mysql_db_query("$basedatos",$sSQL);
?><!DOCTYPE html>

<html lang="<?php echo $lang_actual ?>">

<head>
    <meta charset="utf-8">


<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1, user-scalable=no">

      <? $link_titulo = str_replace('http://', 'https://', $link_titulo); echo $link_titulo;?>
      <? $link_bajada = str_replace('http://', 'https://', $link_bajada); echo $link_bajada;?>
      <? $link_menu = str_replace('http://', 'https://', $link_menu); echo $link_menu;?>

<title><?php echo $titulo ?></title>
<?php $bajada1 = str_replace('"','',$bajada);  ?>
<meta name="description" content="<?php echo $bajada1 ?>" />
<meta name="keywords" content="<?php echo $tag1 ?>, <?php echo $tag2 ?>, <?php echo $tag3 ?>, <?php echo $tag4 ?>, <?php echo $tag5 ?>">
<meta name="language" content="<?php echo $lang_actual ?>" />
<!--
<link rel="canonical" href="<? echo "$dom/nota/$ID/".urls_amigables($titulo).""; ?>" />
<link rel="amphtml" href="<? echo "$dom/nota-amp/$ID/".urls_amigables($titulo).""; ?>"/>
-->
<meta property="og:type" content="article" />
<meta property="og:title" content='<?php echo str_replace ('"','&#x22;',$titulo); ?>' />
<meta property="og:description" content="<?php echo $bajada1 ?>" />
<meta property="og:url" content="<?php echo $dom ?>/nota/<?php echo $ID ?>/<?php echo urls_amigables($titulo) ?>" />
<?php if ($foto == '') {?>
<meta property="og:image" content="https://x7.com.ar/gero/nofoto.png"  /> <? } else {?>
<meta property="og:image" content="<? echo $dom;?>/<?php echo $carpetafoto ?>/resize_<?php echo $foto ?><?php echo $ext_img ?>" /> <?php };?>

<meta name="date" content="<? echo  $a ?>-<? echo str_pad($m, 2, '0', STR_PAD_LEFT); ?>-<? echo str_pad($d, 2, '0', STR_PAD_LEFT); ?>" scheme="YYYY-MM-DD">


<? echo $head_en_concha; ?>

<!-- XXXX  -->

<?php


$catba = $_GET['cat'];

$i_publi = 10000000;

?>

<link rel="shortcut icon" href="<?php echo $dom ?>/icono.ico" type="image/x-icon" />
<!-- 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 href="https://radioshosting.com/css/delalora<? echo $estiloweb ?>new.css" rel="stylesheet">
<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">



    <script src="https://code.jquery.com/jquery-3.4.1.min.js"
        integrity="sha256-CSXorXvZcTkaix6Yvo6HppcZGetbYMGWSFlBw8HfCJo=" crossorigin="anonymous"></script>
		<!-- HTML5 Shim and Respond.js IE8 support of HTML5 elements and media queries -->
		<!-- WARNING: Respond.js doesn t work if you view the page via file:// -->
		<!--[if lt IE 9]>
			<script src="https://oss.maxcdn.com/libs/html5shiv/3.7.0/html5shiv.js"></script>
			<script src="https://oss.maxcdn.com/libs/respond.js/1.4.2/respond.min.js"></script>
		<![endif]-->
<script>
                                                        (function(d, s, id) {
                                                        var js, fjs = d.getElementsByTagName(s)[0];
                                                        if (d.getElementById(id)) return;
                                                        js = d.createElement(s); js.id = id;
                                                        js.src = "//connect.facebook.net/es_LA/all.js#xfbml=1&appId=427523193949843";
                                                        fjs.parentNode.insertBefore(js, fjs);
                                                        }(document, 'script', 'facebook-jssdk'));
                                                    </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?>;

        }



        p > a {
            display: initial;
            color: #111;
            text-decoration: underline !important;
        }



        .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 <?php echo $d_color_menu ?>;
        }

        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?> !important;
        }

        .widget-title {
            font-size: 25px;
            font-weight: 900;
            line-height: 1;
            text-transform: uppercase;
            margin-bottom: 0;
            color: <?php echo $d_color_menu ?>;
            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?>;
        }
    </style>
	</head>


<body>


<!-- ESTO ES LA CABECERA EL HEAD -->

<?php if ($estiloweb == 72 ) { include 'menu_magazine.php'; }; ?>


        <!-- ESTO ES EL CUERPO DE LA PAGINA, PEUDE ESTAR CONTENIDO O NO -->


            <div class="bg-light <?if ($opcion101 == 1) { echo 'container-fluid';} if ($opcion101 == 0) {echo 'container';}?> pt-3">

                <div id="main-content" class="row main">

                            <div id="content" class="content col-12 col-sm-8 p-0 col-md-8 col-lg-8 " >

                                <!-- ACA empieza -->



                                    <div class="col-lg-12 col-12 base-box2" style="display: flex; justify-content: space-between;">
                                        <?
                                        $Y = $a;
                                        $M = $m2;
                                        $D = $d;
                                        $date = "$Y$M$D";
                                        if ($M == '01') {$m = "enero";};
                                        if ($M == '02') {$m = "febrero";};
                                        if ($M == '03') {$m = "marzo";};
                                        if ($M == '04') {$m = "abril";};
                                        if ($M == '05') {$m = "mayo";};
                                        if ($M == '06') {$m = "junio";};
                                        if ($M == '07') {$m = "julio";};
                                        if ($M == '08') {$m = "agosto";};
                                        if ($M == '09') {$m = "septiembre";};
                                        if ($M == '10') {$m = "octubre";};
                                        if ($M == '11') {$m = "noviembre";};
                                        if ($M == '12') {$m = "diciembre";};
                                        ?>

                                        <?php if ($cat_no == 0) {} else {
                                        $sql2 = "SELECT * FROM categorias WHERE ID = '$cat_no' LIMIT 1";
                                        $consulta2 = mysql_query ($sql2);
                                        while ($row2 = mysql_fetch_array($consulta2))
                                        {
                                        $cat_nom = $row2["nombre"];
                                        $color_cat = $row2["color"];
                                        }
                                        mysql_free_result($consulta2);
                                        ?>

                                        <?
                                        if ($cat_nom != '' || $cat_nom != NULL){
                                        ?>
                                            <div style="background-color: <? if ($color_cat == '' or $color_cat == '#FFFFFF') { echo "#666666"; } else { echo $color_cat; }; ?>">
                                                <p class="m-0 py-1 px-2" style="font-family:<?php echo $style_titulo ?>;color:#FFFFFF;">
                                                <?php echo strtoupper($cat_nom); ?>
                                                </p>
                                            </div>
                                        <?
                                        } else {?>

                                            <div>
                                                <p class="m-0 py-1 px-2">
                                                <?php echo strtoupper($cat_nom); ?>
                                                </p>
                                            </div>

                                        <?}
                                        ?>



                                        <? };?>

                                        <? if ($apagar_la_fecha == 1) {} else { ?>
                                        <div>
                                            <p class="m-0 py-1 px-2" style=";font-family:<?php echo $style_titulo ?>;font-size:14px;color:<?php echo $d_color_titulo?>;">
                                                <?php echo $D ?> de <?php echo $m ?> de <?php echo $a ;?>
                                            </p>

                                        </div>
  <?}  ?>

                                    </div>

                                    <div class="col-lg-12 col-12 base-box2 p-0 px-md-3">

                                        <div class="mb-3">

                                                      <script>
                                                          $(document).ready(function () {

                                                              // FETCHING DATA FROM JSON FILE
                                                              $.getJSON("http://original.radiosnet.com.ar/nota_json.php?nota=1",
                                                                      function (data) {
                                                                  var compra = '';
                                                                  var venta = '';
                                                                  var comprab = '';
                                                                  var ventab = '';

                                                                  // ITERATING THROUGH OBJECTS
                                                                  $.each(data, function (key, value) {

                                                                      //CONSTRUCTION OF ROWS HAVING
                                                                      // DATA FROM JSON OBJECT
                                                                      titulo = value.titulo;
                                                                      venta = value.venta;
                                                                      comprab = value.comprab;
                                                                      ventab = value.ventab;


                                                                  });

                                                                  //INSERTING ROWS INTO TABLE
                                                                  $('#titulo').append(titulo);
                                                                    $('#venta').append(venta);
                                                                    $('#comprab').append(comprab);
                                                                    $('#ventab').append(ventab);


                                                              });
                                                          });
                                                      </script>

                                            <h2 id="titulo" style="padding: 15px;font-family:<?php echo $style_titulo ?>;color:<?php echo $d_color_titulo?>;"></h2>

                                        </div>

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

                                                ?>

                                                <div class="col-lg-12 col-12 p-0">

                                                    <?php     if ($ejemplo_marca_de_agua == NULL) {  ?>

                                                                <div id="cont_foto" align="left"></div>
                                                    <?php   } else {?>
                                                            <div align="left"><img class="<? if ($estiloweb <= 3){echo "img-responsive";} else {echo "img-fluid";} ?>"  src="<? echo $dom ?>/<?php echo $ejemplo_marca_de_agua ?>?i=<?php echo $carpetafoto ?>/resize_<?php echo $foto ?><? echo $ext_img ?>" /></div>
                                                    <?php };?>

                                                    <?php if ($pie_foto == '') { } else {?>

                                                    <p style="padding:0;
                                                    font-size: 13px;
                                                    line-height: 18px;
                                                    color: rgb(175, 174, 174);
                                                    font-family: Roboto, sans-serif;
                                                    font-weight: 700;
                                                    margin-left: 0px !important;
                                                    letter-spacing: 1px;
                                                    "><?php echo $pie_foto ?></p>

                                                        <?php };?>

                                                </div>

                                            <?php };?>

                                            <?php
                                            if ($ID_editor == 0) {} else {
                                            $sql65 = "SELECT * FROM editores WHERE ID = '$ID_editor' LIMIT 1";
                                            $consulta65 = mysql_query ($sql65);
                                            while ($row65 = mysql_fetch_array($consulta65))
                                            {
                                            $nombre_editor = $row65["nombre"];
                                            $telefono_editor = $row65["telefono"];
                                            $email_editor = $row65["email"];
                                            $instagram_editor = $row65["instagram"];
                                            $facebook_editor = $row65["facebook"];
                                            $twitter_editor = $row65["twitter"];
                                            $foto_editor = $row65["foto"];
                                            $ID_editor = $row65["ID"];
                                            }
                                            mysql_free_result($consulta65);
                                            ?>

                                            <div class="row">

                                                <div class="col-2 col-2 col-sm-2 col-md-2 col-lg-2" style="padding:10px;">

                                                    <img class="img-fluid img-responsive" src="<?php echo $foto_editor ?>" data-hidpi="#" style="max-height:60px;margin:0 auto;border-radius:50%!important;">

                                                </div>

                                                <div class="col-10 col-10 col-sm-10 col-md-10 col-lg-10" style="padding:10px;">

                                                    <b>Por: <?php echo $nombre_editor ?>

                                                    </b>

                                                    <ul class="navbar-nav ml-auto" style="display:inline-block;">

                                                        <?php  if ($facebook_editor == '') {} else {?>

                                                        <li class="nav-item2" style="display:inline-flex;margin-right:10px;">

                                                            <a href="<?php echo $facebook_editor ?>" style="padding:0;" target="_blank">

                                                                <h4 style="margin:0; padding:0.5em;" ><i class="fab fa-facebook-square" style="font-size:1.5em;"></i></h4>

                                                            </a>

                                                        </li> <?php };?>
                                                        <?php  if ($twitter_editor == '') {} else {?>

                                                        <li class="nav-item2" style="display:inline-flex;margin-right:10px;">

                                                            <a href="<?php echo $twitter_editor ?>" style="padding:0;" target="_blank">

                                                                <h4 style="margin:0; padding:0.5em;" ><i class="fab fa-twitter-square" style="font-size:1.5em;"></i></h4>

                                                            </a>

                                                        </li>
                                                        <?php };?><?php  if ($instagram_editor == '') {} else {?>
                                                        <li class="nav-item2" style="display:inline-flex;margin-right:10px;">

                                                            <a href="<?php echo $instagram_editor ?>" style="padding:0;" target="_blank">

                                                                <h4 style="margin:0; padding:0.5em;" ><i class="fab fa-instagram" style="font-size:1.5em;"></i></h4>

                                                            </a>

                                                        </li> <?php };?><?php  if ($email_editor == '') {} else {?>

                                                        <li class="nav-item2" style="display:inline-flex;margin-right:10px;">

                                                            <a href="mailto:<?php echo $email_editor ?>" style="padding:0;" target="_blank">

                                                                <h4 style="margin:0; padding:0.5em;" ><i class="fas fa-envelope" style="font-size:1.5em;"></i></h4>

                                                            </a>

                                                        </li><?php };?>

                                                    </ul>

                                                </div>

                                            </div>

                                            <?php }; //finaliza if de editores?>



                                        <div class="grid mt-3 fg">



                                                <?php

if ($ref_fotos_notas == 1) {


                                                $sql65 = "SELECT * FROM fotos_notas WHERE noticia = '$ID'";
                                                $consulta65 = mysql_query ($sql65);
                                                while ($row65 = mysql_fetch_array($consulta65))
                                                {
                                                $carpetafoto1 = $row65["carpetafoto"];
                                                $ID_foto = $row65["ID"];
                                                $foto = $row65["foto"];
                                                ?>

                                            <div class="grid-item col-lg-2 col-md-3 col-sm-12 col-12" style="margin-bottom:15px;" >
                                                <a data-lightbox="example-set"   href="<?php echo $dom ?>/<?php echo $carpetafoto1 ?>/resize_<?php echo $foto ?>.jpg"  title="<?php echo $titulo; ?>">
                                                    <img src="<?php echo $dom ?>/<?php echo $carpetafoto1 ?>/thumbnail_<?php echo $foto ?>.jpg" class="img-fluid" />
                                                </a>
                                            </div>

                                            <?
                                            }
                                            mysql_free_result($consulta65);

                                          };
                                            ?>



                                            <?php


                                            if ($ref_fotosnotasfull == 1) {

                                            $sql65 = "SELECT * FROM `fotosnotasfull` WHERE `ID_nota` = '$ID'";
                                            $consulta65 = mysql_query ($sql65);
                                            while ($row65 = mysql_fetch_array($consulta65))
                                            {
                                            $ID_foto = $row65["ID"];
                                            $img = $row65["img"];

                                            ?>

                                            <div class="grid-item col-lg-2 col-md-3 col-sm-12 col-12" style="margin-bottom:15px;"  >
                                                <a href="<?php echo $img ?>" rel="lightbox[<?php echo $ID ?>]" title="<?php echo $titulo; ?>"><img src="<?php echo $dom ?>/timthumb.php?src=<?php echo $img;?>&w=500&q=80" class="img-fluid" /></a>
                                            </div>

                                            <?
                                            }
                                            mysql_free_result($consulta65);

                                            };
                                            ?>

                                        </div>


                                        <div class="col-lg-12 col-12 mb-3">

                                            <p id="bajada" style="font-family:<?php echo $style_bajada  ?>;"></p>

                                        </div>


<? echo $ads_bajada_1 ?>



                                        <?php


                                            $sql = "SELECT * FROM  `publicidades_gif` WHERE ID_lugar = '$cat' AND lugar = '$cat_no'";
                                            $consulta = mysql_query ($sql);

                                            while ($row = mysql_fetch_array($consulta))
                                            {
                                            $ID_p = $row["ID"];
                                            $img = $row["img"];
                                            $carpetafoto = $row["carpetafoto"];
                                            $url  = $row["url"];
                                            ?>

                                            <a href="<?php echo $url ?>" target="_blank">

                                                <img class="img-responsive publi-index" src="<?php echo $dom ?>/<?php echo $carpetafoto ?>/<?php echo $img ?>" width="100%"  />

                                            </a>

                                            <?
                                            }
                                            mysql_free_result($consulta);
                                            ?>
                                            <?php if ($ref_audio == 1) { ?>

                                            <div class="col-lg-12 col-12 mb-3">

                                                <?php include 'audio_new.php'; ?>

                                            </div>

                                            <?php  } ?>

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

                                            <div class="col-lg-12 col-12 mb-3">

                                                <div  style="position: relative; padding-bottom: 56.25%;">

                                                    <iframe style="position: absolute;width: 100%; height: 100%;" src="https://www.youtube.com/embed/<?php echo $youtube ?>" frameborder="0" allowfullscreen></iframe>

                                                </div>


                                            </div>

                                            <?php  }?>


                                            <div class="col-lg-12 col-12 mb-3">

                                                <!-- -->

                                                <div id="fb-root"></div>



                                                <!-- Rotativas -->
<? if ($ref_rotativas  == 1){ ?>
                                                <div class="col-lg-12 col-12 p-0 mb-3 d-flex justify-content-center py-3">

                                                    <?php include 'rotativas_random_arriba.php';?>

                                                </div>
<? } ?>
                                                <!-- Rotativas -->

                                                <div id="texto" class="col-lg-12 col-12 p-0">



                                                </div>



<? echo $ads_bajada_2 ?>



                                                <!-- -->
                                                <?php if ($html == NULL) {} else { ?>
                                                <div style="position:relative;padding-bottom:56.25%;">

                                                    <?php echo $html?>

                                                </div>
                                                <?php  }?>

                                                <!-- -->

                                                <!-- -->


                                                    <?php
                                                    if ($ref_videos  == 1){
                                                    $sql65 = "SELECT * FROM videos WHERE ID_nota = '$ID' LIMIT 1";
                                                    $consulta65 = mysql_query ($sql65);
                                                    while ($row65 = mysql_fetch_array($consulta65))
                                                    {
                                                    $ID_video = $row65["ID"];
                                                    $video = $row65["video"];

                                                    if(!video) { } else { ?>

                                                    <div class="col-lg-12 col-12 mb-3">
                                                        <div >

                                                            <video controls style="width:100%;">
                                                              <source src="<?php echo $video ?>" type="video/mp4">
                                                            Su Navegador no Soporta Video</video>
                                                        </div>
                                                       </div>
                                                    <?php }

                                                    } mysql_free_result($consulta65);

} //cierro if rel_
                                                    ?>



                                                <!-- -->

                                                <div class="col-lg-12 col-12">

                                                    <style>
                                                        .fb-like > span > iframe {
                                                            width: 2100%!important;
                                                        }
                                                    </style>

                                                    <div class="fb-like" data-href="<?php echo $dom ?>/nota/<?php echo $ID ?>/<?php echo urls_amigables($titulo) ?>"
                                                    data-layout="button_count" data-action="like" data-size="large" data-show-faces="true" data-share="true"></div>

                                                </div>

                                                <!-- -->
<? if ($ref_archivos == 1) { ?>
                                                <div class="col-lg-12 col-12">

                                                        <?php

                                                        $sql65 = "SELECT * FROM archivos WHERE ID_nota = '$ID_NOTA'";
                                                        $consulta65 = mysql_query ($sql65);
                                                        while ($row65 = mysql_fetch_array($consulta65))
                                                        {


                                                        $ruta = $row65["ruta"];
                                                        $tipo = $row65["tipo"];

                                                        if ($tipo == 'pdf') { echo "<iframe src='$ruta' width='100%' height='500px'></iframe>" ; };?>

                                                        <a class="btn" target="_blank" href="<?php echo $ruta ?>"><img src="<?


                                                        if ($tipo == 'xls' or $tipo == 'xlsx') { echo "https://radiosnet.com.ar/xls.png"; };

                                                        if ($tipo == 'doc' or $tipo == 'docx') { echo "https://radiosnet.com.ar/doc.png"; };


                                                        ?>" /></a>
                                                        <?
                                                        }
                                                        mysql_free_result($consulta65);
                                                        ?>
                                                </div>
                                                <?
                                              }//// cierro if rel_
                                                ?>
                                                <!-- Rotativas -->
<? if ($ref_rotativas  == 1){ ?>
                                                <div class="col-lg-12 col-12 p-0 mb-3 d-flex justify-content-center py-3">

                                                    <?php include 'rotativas_random_abajo.php';?>

                                                </div>
<? } ?>
                                                <!-- Rotativas -->

                                                <div class="col-lg-12 col-12">

                                                    <h4>COMPARTIR:</h4>

                                                    <ul class="navbar-nav flex-row ml-md-auto d-md-flex">

                                                        <li class="nav-item">
                                                            <a style="margin-left:10px;" target="_blank" href="https://www.facebook.com/sharer.php?u=<?php echo $dom ?>/nota/<?php echo $ID ?>/<?php echo urls_amigables($titulo) ?>&t=<?php echo $titulo ?>">
                                                                <i class="fab fa-facebook" style="font-size:30px;color:#111111; " aria-hidden="true"></i>
                                                            </a>
                                                        </li>

                                                        <li class="nav-item">
                                                            <a style="margin-left:10px;" target="_blank" href="https://twitter.com/share?original_referer=<?php echo $dom ?>/nota/<?php echo $ID ?>/<?php echo urls_amigables($titulo_xx) ?>&amp;source=tweetbutton&amp;text=<?php echo $titulo_xx; ?>&amp;url=<?php echo $dom ?>/nota/<?php echo $ID ?>/<?php echo urls_amigables($titulo_xx) ?>">
                                                                <i class="fab fa-twitter" style="font-size:30px;color:#111111; " aria-hidden="true"></i>
                                                            </a>
                                                        </li>

                                                        <li class="nav-item">
                                                            <a style="margin-left:10px;" target="_blank" href="https://api.whatsapp.com/send?text=*<?php echo $titulo_xx ?>.*  <?php echo $dom ?>/nota/<?php echo $ID ?>/<?php echo urls_amigables($titulo_xx);?>">
                                                                <i class="fab fa-whatsapp" style="font-size:30px;color:#111111; " aria-hidden="true"></i>
                                                            </a>
                                                        </li>
                                                    </ul>


                                                </div>

                                                <!-- -->

                                                <div class="col-lg-12 col-12 my-3 px-0 py-3">

                                                                <div class="col-12 col-lg-12 my-3 p-0">

                                                                    <h3 style="font-family:<?php echo $style_titulo ?>;color:<?php echo $d_color_titulo?>;">Notas Relacionadas</h3>

                                                                </div>


                                                                <div id="cont_rel" class="main-carousel" data-flickity='{ "cellAlign": "left", "imagesLoaded": true, "wrapAround": true, "pageDots": false }'>





                                                                </div>


                                                </div>

                                                <!-- -->



                                                <!-- -->

                                                <div class="col-12">

                                                    <?php if ($opcion3 == 'si') { ?>
                                                    <div class="col-12"><h3 style="">Comentarios</h3></div>
                                                    <? if ($comentarios == 'facebook') {?>
                                                        <div class="col-12">
                                                                        <div class="fb-comments" reverse="false" data-href="<? echo $dom;?>/nota/<?php echo $ID ?>/<?php echo urls_amigables($titulo) ?>" data-num-posts="100" data-width="100%"  data-order-by="reverse_time";></div>
                                                                    </div>
                                                    <?}else{?>
                                                        <div class="col-12">
                                                                                <form id="form1" name="form1" method="post" action="<? echo $dom;?>/formcomentario.php?IDD=<?php echo $ID_NOTA ?>">

                                                                                                Escribir un comentario &raquo;<br>

                                                                                                <div class="form-group">

                                                                                                <input name="nombre" type="text" class="form-control" id="nombre" value="nombre" size="12" onFocus="if (this.value == 'nombre') {this.value = '';}" placeholder="Nombre"/>
                                                                                                <textarea name="texto" rows="4" class="form-control"  onFocus="if (this.value == 'comentario') {this.value = '';}" placeholder="Comentario"></textarea>
                                                                                                </div>
                                                                                        <div  class="form-group">


                                                                                     <div style="text-align:center;margin-bottom:20px;">
                                                                                  <button name="button" type="submit" id="button" value="Enviar" />Enviar</button>
                                                                                                </div>
                                                                                            </div>
                                                                                </form>
                                                                    </div>
                                                        <div class="col-12">
                                                                            <?

                                                                            $c = 0;
                                                                            if ($ref_comentarios == 1) {
                                                                            $sql = "SELECT * FROM comentarios WHERE IDD = '$ID_NOTA' AND ver = 'si' ";
                                                                            $consulta = mysql_query ($sql);
                                                                            while ($row = mysql_fetch_array($consulta))
                                                                            {
                                                                            $c = $c + 1;
                                                                            $ID_comentario = $row["ID"];
                                                                            $nombre = $row["nombre"];
                                                                            $texto = $row["texto"];
                                                                            ?>

                                                                            <div class="border-top py-3">
                                                                                <p><b>Nombre</b><br><?php echo $nombre ?></p>
                                                                                <p><b>Comentario</b><br><?php echo $texto ?></p>
                                                                                <a href="<?php echo $dom ?>/responder_comentario.php?ID_comentario=<?php echo $ID_comentario ?>" class="btn btn-outline-primary my-2">Responder</a>
                                                                            </div>

                                                                            <?php

                                                                            $sql33 = "SELECT * FROM comentarios WHERE sub_comentario = '$ID_comentario' AND ver = 'si' ";
                                                                            $consulta33 = mysql_query ($sql33);
                                                                            while ($row33 = mysql_fetch_array($consulta33))
                                                                            {
                                                                                $nombre33 = $row33["nombre"];
                                                                                $mensaje33 = $row33["texto"];

                                                                                ?>

                                                                                <div class="pl-3">
                                                                                    <p><b>Nombre</b><br><?php echo $nombre33 ?></p>
                                                                                    <p><b>Comentario</b><br><?php echo $mensaje33 ?> </p>
                                                                                </div>



                                                                            <?php } mysql_free_result($consulta33); ?>


                                                                        <?php }
                                                                        //echo $c;
                                                                        mysql_free_result($consulta);

                                                                      } ///cierro if rel_

                                                                        if ($c == 0) { ?>

                                                                        <p>Aun no hay comentarios, sé el primero en escribir uno!</p>


                                                                        <? } ?>
                                                                    </div>
                                                    <?php };} else {};?>

                                                </div>

                                            </div>

                                    </div>

                                <!-- ACA termina-->

                            </div>

                            <div id="sidebar" class="sidebar col-12 col-sm-4 col-md-4 p-0 col-lg-4 ">
                                    <div class="sidebar__inner">
                                        <?  include 'propagandas_div.php'; ?>
                                    </div>
                            </div>

                </div>

            </div>

            <!-- esto es el footer -->
            <?php if ($estiloweb == 72) { include 'footer.magazine.php'; }; ?>

            <? include 'clix_footer.php';?>
		    <!-- termina el footer -->
		    <script>
    // Set the options to make LazyLoad self-initialize
    window.lazyLoadOptions = {
        elements_selector: ".lazy",
        // ... more custom settings?
    };
    // Listen to the initialization event and get the instance of LazyLoad
   // window.addEventListener('LazyLoad::Initialized', function (event) {
   //     window.lazyLoadInstance = event.detail.instance;
   // }, false);
</script>
<script async src="https://cdn.jsdelivr.net/npm/vanilla-lazyload@12.4.0/dist/lazyload.min.js"></script>

<script src="https://cdnjs.cloudflare.com/ajax/libs/wow/1.1.2/wow.min.js"></script>
        <script>
           // new WOW().init();
            //  console.log('asdasd34');
        </script>
    <!-- ESTO SON TODOS LOS JS QUE USA EL SITIO -->
    <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://radioshosting.com/css/js/lightbox-plus-jquery.min.js"></script>
            <script src="<?php echo $dom;?>/js/jquery.fittext.js"></script>
            <script src="https://unpkg.com/isotope-layout@3/dist/isotope.pkgd.js"></script>
            <script src="https://unpkg.com/flickity@2/dist/flickity.pkgd.min.js"></script>
            <script type="text/javascript">
            window.setInterval(function(){
            /*$('.grid').isotope({
            itemSelector: '.grid-item'
            });
            }, 2000);*/});
            </script>
            <script type="text/javascript">
            window.setInterval(function(){
            $('.grid2').isotope({
            itemSelector: '.grid-item2'
            });
            }, 2000);

            </script>
            <script language=javascript>
            function ventanaSecundaria56 (URL){
            window.open(URL,"ventana1","width=960,height=630,scrollbars=NO")
            }
            </script>

                <!--script type="text/javascript" src="<?php echo $dom;?>/js/rAF.js"></script>
    <script type="text/javascript" src="<?php echo $dom;?>/js/ResizeSensor.js"></script>
    <script type="text/javascript" src="https://cdn.jsdelivr.net/npm/sticky-sidebar@3.3.1/dist/sticky-sidebar.js">
    </script-->

    <script type="text/javascript">

             var TIMEOUT = null;

            $(window).on('resize', function () {
                if (TIMEOUT === null) {
                    TIMEOUT = window.setTimeout(function () {
                        TIMEOUT = null;
                        //fb_iframe_widget class is added after first FB.FXBML.parse()
                        //fb_iframe_widget_fluid is added in same situation, but only for mobile devices (tablets, phones)
                        //By removing those classes FB.XFBML.parse() will reset the plugin widths.
                        $('.fb-page').removeClass('fb_iframe_widget fb_iframe_widget_fluid');

                        FB.XFBML.parse();
                    }, 300);
                }
            });


        // console.log(sidebar);
        //$(function() {
//
        //  let valorDelSidebar = document.querySelector('.sidebar__inner');
        //  console.log(valorDelSidebar);
        //  if (valorDelSidebar.childElementCount == 0){
        //      document.querySelector('#sidebar').classList = 'd-none';
        //      document.querySelector('#content').classList = 'col-12';
        //  } else {
        //      var sidebar = new StickySidebar('#sidebar', {
        //          containerSelector: '#main-content',
        //          innerWrapperSelector: '.sidebar__inner',
        //          resizeSensor: true,
        //          topSpacing: 60,
        //          bottomSpacing: 20,
        //          minWidth: 768
        //    });
        //  }
//
        //});



    var a = $(".carousel-captionh1").fitText(1.2, { minFontSize: '14px', maxFontSize: '18px' });
        $(".colorTitulo").fitText(1.2, { minFontSize: '14px', maxFontSize: '24px' });
        $(".carousel-caption h2").fitText(1.2, { minFontSize: '14px', maxFontSize: '30px' });
        $(".tituloVideo").fitText(1.2, { minFontSize: '14px', maxFontSize: '30px' });
        $(".tarso").fitText(1.2, { minFontSize: '20px', maxFontSize: '50px' });
        $(".tarso2").fitText(1.2, { minFontSize: '5px', maxFontSize: '11px' });

        jQuery('img.svg').each(function(){
           var $img = jQuery(this);
           var imgID = $img.attr('id');
           var imgClass = $img.attr('class');
           var imgURL = $img.attr('src');
           //console.log('lalasl', imgURL);
           jQuery.get(imgURL, function(data) {

               // Get the SVG tag, ignore the rest
               var $svg = jQuery(data).find('svg');

               // Add replaced image's ID to the new SVG
               if(typeof imgID !== 'undefined') {
                   $svg = $svg.attr('id', imgID);
               }
               // Add replaced image's classes to the new SVG
               if(typeof imgClass !== 'undefined') {
                   $svg = $svg.attr('class', imgClass+' replaced-svg');
               }

               // Remove any invalid XML tags as per http://validator.w3.org
               $svg = $svg.removeAttr('xmlns:a');

               // Check if the viewport is set, else we gonna set it if we can.
               /*if(!$svg.attr('viewBox') && $svg.attr('height') && $svg.attr('width')) {
                   $svg.attr('viewBox', '0 0 ' + $svg.attr('height') + ' ' + $svg.attr('width'))
               }*/

               // Replace image with new SVG
               $img.replaceWith($svg);

           }, 'xml');

        });
    });
            </script>



            <script>

//renzo
            // agarrar el titulo
            const cont = document.getElementById('nota-container');
            const cont_foto = document.getElementById('cont_foto');
            const titulo = document.getElementById('titulo');
            const bajada = document.getElementById('bajada');
            const url_nota = document.getElementById('url_nota');
            const texto = document.getElementById('texto');

            var imagen = document.createElement("img");

            var img;
            // API url
            // http://original.radiosnet.com.ar/nota_json.php?nota=1

            fetch('https://original.radiosnet.com.ar/json_nota_mysqli.php?ID=<? echo $ID_NOTA ?>')
                // Exito
              .then(response => response.json())
              .then(data => agregarData(data))


            function agregarData(dataReq){
              console.log(dataReq)
              titulo.innerHTML = `<a href="${dataReq.nota.url_nota}">${dataReq.nota.titulo}</a>`;
              bajada.innerHTML = dataReq.nota.bajada;
              imagen.src = dataReq.nota.foto;
              texto.innerHTML = dataReq.nota.texto;



              img = `<a href="${dataReq.nota.url_nota}"><img class="img-fluid" src="<? echo $dom ?>/${dataReq.nota.carpetafoto}/thumbnail_${dataReq.nota.foto}${dataReq.nota.ext_img}" alt="${dataReq.nota.titulo}" /></a>`
              cont_foto.innerHTML += img


            }




            </script>
<?php include 'google.php';?>
</body>
</html>
