// -- Carga asincronica de los scripts. $LAB .script("/js/jquery/jquery.js") .wait() .script("/js/jquery/jquery.menu.pack.js") .script("/js/jquery/jquery.scrollTo.js") .wait() .script("/js/jquery/jquery.serialScroll.js") .script("/js/jquery/jquery.taconite.js") .script("/js/shadowbox20.js") .wait() .script("/js/skin/classic/skin.js") .wait( function() { jQuery.noConflict(); // -- Actualiza la información del perfil. // setTimeout("updateLoginInfo()", 250 ); // -- Shadowbox if (typeof Shadowbox != 'undefined') { var options = { overlayBgImage : '/images/overlay-85.png', loadingImage : '/images/loading-light.gif', animate : true, text: { cancel: 'Cancelar', loading: 'cargando', close: 'Cerrar', next: 'Próxima', prev: 'Anterior', errors: { single: 'You must install the {1} browser plugin to view this content.', shared: 'You must install both the {1} and {3} browser plugins to view this content.', either: 'You must install either the {1} or the {3} browser plugin to view this content.' } }, keysClose: ['c', 'q', 27], // c, q, or esc keysNext: ['p', 39], // n or right arrow keysPrev: ['a', 37] // p or left arrow } Shadowbox.init(options); } // -- Chequea si se está en la home del sitio. if ( jQuery("#esta-edicion-container").length > 0 ) { initHomePage(); } else if( jQuery("#news-header").length > 0 ) { initNewsPage(); } else { initCommonPage(); } }); function initHomePage() { $LAB .script("/sf/calendar/calendar.js") .block() .script("/sf/calendar/calendar-setup.js") .script("/sf/calendar/lang/calendar-es.js") .script("/js/jquery/jquery.ifixpng.js") .wait() .script("/scripts/home.html") .block(function() { jQuery.getScript("/js/home.js"); }); } function initNewsPage() { var newsId = jQuery("#news-comments-form-container").attr("rel"); // -- Actualiza la información dinámica. jQuery.post("/light.php", { module : "common", action : "updateNews", id : newsId }, function() { $LAB .script("/js/swfobject.js") .script("/js/jquery/jquery.maxlength.js") .script("/js/jquery/jquery.metadata.js") .script("/js/flowplayer-3.1.4.min.js") .wait() .script("/js/news.js"); } ); } function initCommonPage() { // -- Actualiza la información dinámica. jQuery.post("/light.php", { module : "common", action : "updateCommon" } ); } function updateLoginInfo() { var data = { "module" : "common", "action" : "loginHeader" }; jQuery("#header-login-container").load("/light.php", data ); }