| Server IP : 89.248.107.232 / Your IP : 216.73.217.70 Web Server : Apache System : Linux host2.kasilh.com 5.14.0-687.36.1.el9_8.x86_64 #1 SMP PREEMPT_DYNAMIC Fri Aug 7 05:40:49 EDT 2026 x86_64 User : seg ( 10005) PHP Version : 7.4.33 Disable Function : opcache_get_status MySQL : OFF | cURL : ON | WGET : OFF | Perl : OFF | Python : OFF | Sudo : OFF | Pkexec : OFF Directory : /var/www/vhosts/seg-sa.es/marenostrumingenieros.com/wp-content/themes/advtheme/js/ |
Upload File : |
var aux = 0;
$("nav#site-navigation .menu-menu-1-container ul li").hover(function(){
$(this).addClass("activo");
}, function(){
$(this).removeClass("activo");
});
$(".efecto-hover").hover(function(){
$(this).addClass("activo");
}, function(){
$(this).removeClass("activo");
});
$("#btn-menu-movil").click(function(){
$(".sidenav").addClass("mostrar");
});
$("#cerrar-sidenav").click(function(){
$(".sidenav").removeClass("mostrar");
});
$(document).ready(function() {
$('.flecha-bajar a[href^="#"]').click(function() {
var destino = $(this.hash);
if (destino.length == 0) {
destino = $('a[name="' + this.hash.substr(1) + '"]');
}
if (destino.length == 0) {
destino = $('html');
}
$('html, body').animate({ scrollTop: destino.offset().top }, 1000);
return false;
});
$('a[href^="#anclaform"]').click(function() {
var destino = $(this.hash);
if (destino.length == 0) {
destino = $('a[name="' + this.hash.substr(1) + '"]');
}
if (destino.length == 0) {
destino = $('html');
}
$('html, body').animate({ scrollTop: destino.offset().top }, 1000);
return false;
});
});
$(function() {
jQuery('#url').val(document.URL);
//myFunction();
//$( "body" ).css( "display", "block");
});
//window.onscroll = function() {myFunction()};
function myFunction() {
if (aux == 0) {
if (document.body.scrollTop > 50 || document.documentElement.scrollTop > 50) {
document.getElementById("masthead").className = "fixed";
} else {
document.getElementById("masthead").className = "";
}
}
}
var acc = document.getElementsByClassName("accordion");
var i;
for (i = 0; i < acc.length; i++) {
acc[i].addEventListener("click", function() {
this.classList.toggle("active");
var panel = this.nextElementSibling;
if (panel.style.maxHeight){
panel.style.maxHeight = null;
} else {
panel.style.maxHeight = panel.scrollHeight + "px";
}
});
}
function validar_contacto(form){
var mensaje = "";
var swi = 0;
if(form.nombre.value.length === 0){
swi = 1; mensaje+="Introduce por favor tu nombre\n";
}
if (form.email.value.indexOf('@', 0) === -1 || form.email.value.indexOf('.', 0) === -1) {
swi = 1; mensaje += "Introduce por favor un email válido\n";
}
if (form.telefono.value.length === 0) {
swi = 1;
mensaje += "Introduce por favor tu teléfono\n";
}
if (!form.politica.checked) {
swi = 1; mensaje += "Debes aceptar la Política de privacidad\n";
}
if(swi===1) alert(mensaje);
else {
alert("Formulario enviado con éxito");
form.submit();
}
}