";
} else {
// Si es Facebook
var iframe = "
aaaa";
}
}
$('#myModal').find('.modal-body').append(iframe);
$("a.link_youtube").ntg_link_video();
$('#myModal').modal('show');
$('#myModal').on('hidden.bs.modal', function (e) {
$('#myModal').find('.modal-body').empty();
})
}
});
// Portadilla de noticias: si son de otro canal, abrir en nueva pestaña con canal de origen
$(".otro-canal .recuadro .titulo").each(function () {
var clases = $(this).attr("class").split(" ");
if (clases[2] != "cid-" + __cid) {
$(this).find("a").attr("target", "blank");
}
});
// Validar si el recurso foto_portadilla esta incluido en el cuerpo simple del eidox
/******************
** PLACEHOLDER **
******************/
$(".form_text, .form_number").each(function () {
var inp = $("input", this);
//var val = $(inp).val();
var ph = $("span.ntg-formulario-texto-derecha", this);
var val = "";
if (ph) {
val = $(ph).html();
}
$(ph).remove();
$(inp).attr("placeholder", val);
});
/******************
** ICONOS **
******************/
$(".usuario, .home, .password, .telefono, .movil , .direccion ,.email, .numero").each(function () {
$(this).find("input").before("
");
var clase = $(this).attr("class");
if ($(this).hasClass("usuario")) {
$(this).find("div.icon").html("
");
} else if ($(this).hasClass("home")) {
$(this).find(".icon").append("
");
} else if ($(this).hasClass("password")) {
$(this).find(".icon").append("
");
} else if ($(this).hasClass("telefono")) {
$(this).find(".icon").append("
");
} else if ($(this).hasClass("movil")) {
$(this).find(".icon").append("
");
} else if ($(this).hasClass("direccion")) {
$(this).find(".icon").append("
");
} else if ($(this).hasClass("email")) {
$(this).find(".icon").append("
");
} else {
$(this).find(".icon").append("
");
}
$(this).find("div.icon, input").wrapAll("
");
});
/*****************************************************
** Ingresar solo números para los campos numericos **
*****************************************************/
$(".form_number").keypress(function (e) {
//if the letter is not digit then display error and don't type anything
if (e.which != 8 && e.which != 0 && (e.which < 48 || e.which > 57)) {
//display error message
$("#errmsg").html("Digits Only").show().fadeOut("slow");
return false;
}
});
$(".blank a").prop("target","_blank");
if($(".recuadro_recursos").length > 0){
$(".recuadro_recursos .recuadro").each(function(){
if($(this).find(".epigrafe").length < 1){
$(this).find(".titulo a").prop("href",$(this).find(".figure a").prop("href"));
}
else{
$(this).prepend("
");
}
});
}
if(typeof(__pvid) != "undefined"){
if(__pvid=="329015"){
$(".recuadros-3-columnas .recuadro .social .figure").each(function(){
if($(this).find("a").length > 0){
$(this).find("a").prop("target","blank");
if($(this).hasClass("binary-facebook")){
$(this).find("img").prop("src","channels-687_perfil_fb.png");
}
if($(this).hasClass("binary-twitter")){
$(this).find("img").prop("src","channels-687_perfil_tw.png");
}
if($(this).hasClass("binary-instagram")){
$(this).find("img").prop("src","channels-687_perfil_ig.png");
}
if($(this).hasClass("binary-linkedin")){
$(this).find("img").prop("src","channels-687_perfil_lk.png");
}
}
else{
$(this).hide();
}
});
}
}
});
$(window).on("load", function () {
// Validar la miga de pan
if ($(".breadcrumb").length > 0) {
}
});
-->