/*tabs*/
$.tabs = function(containerId, start) {var ON_CLASS = 'on';var id = '#' + containerId;var i = (typeof start == "number") ? start - 1 : 0;$(id + '>div:lt(' + i + ')').add(id + '>div:gt(' + i + ')').hide();$(id + '>ul>li:nth-child(' + (i+1) + ')').addClass(ON_CLASS);$(id + '>ul>li>a').click(function() {$(this).load( function() { alert("Hello"); } );if (!$(this.parentNode).is('.' + ON_CLASS)) {var re = /([_\-\w]+$)/i;var target = $('#' + re.exec(this.href)[1]);if (target.size() > 0) {$(id + '>div:visible').hide();target.show();$(id + '>ul>li').removeClass(ON_CLASS);$(this.parentNode).addClass(ON_CLASS);} else {alert('There is no such container.');}}return false;
});};

/* // Accordion 1.4 // */
jQuery.fn.extend({nextUntil: function(expr) {var match = [];this.each(function(){for( var i = this.nextSibling; i; i = i.nextSibling ) {if ( i.nodeType != 1 ) continue;if ( jQuery.filter( expr, [i] ).r.length ) break;match.push( i );}});return this.pushStack( match );},Accordion: function(settings) {settings = jQuery.extend({}, jQuery.Accordion.defaults, {header: jQuery(':first-child', this)[0].tagName}, settings);if ( settings.navigation ) {var current = this.find("a").filter(function() { return this.href == location.href; });if ( current.length ) {settings.active = current.parent().parent().prev();current.addClass("current");}}var container = this,active = settings.active? jQuery(settings.active, this): settings.active === false? jQuery("<div>"): jQuery(settings.header, this).eq(0),running = 0;var headers = container.find(settings.header);headers.not(active || "").nextUntil(settings.header).hide();active.addClass(settings.selectedClass);function toggle(toShow, toHide, data, clickedActive) {var finished = function(cancel) {running = cancel ? 0 : --running;if ( running )return;container.trigger("change", data);};running = toHide.size() + toShow.size();if ( settings.animated ) {if ( !settings.alwaysOpen && clickedActive ) {toShow.slideToggle(settings.showSpeed);finished(true);} else {toHide.filter(":hidden").each(finished).end().filter(":visible").slideUp(settings.hideSpeed, finished);toShow.slideDown(settings.showSpeed, finished);}} else {if ( !settings.alwaysOpen && clickedActive ) {toShow.toggle();} else {toHide.hide();toShow.show();}finished(true);}}function clickHandler(event) {if ( !event.target && !settings.alwaysOpen ) {active.toggleClass(settings.selectedClass);var toHide = active.nextUntil(settings.header);var toShow = active = jQuery([]);toggle( toShow, toHide );}var clicked = jQuery(event.target);if ( clicked.parents(settings.header).length )while ( !clicked.is(settings.header) )clicked = clicked.parent();var clickedActive = clicked[0] == active[0];if(running || (settings.alwaysOpen && clickedActive) || !clicked.is(settings.header))return;active.toggleClass(settings.selectedClass);if ( !clickedActive ) {clicked.addClass(settings.selectedClass);}var toShow = clicked.nextUntil(settings.header),
toHide = active.nextUntil(settings.header),data = [clicked, active, toShow, toHide];active = clickedActive ? jQuery([]) : clicked;toggle( toShow, toHide, data, clickedActive );return !toShow.length;};function activateHandler(event, index) {if ( index == null )return;clickHandler({target: index >= 0? jQuery(settings.header, this)[index]: typeof index == "string"? jQuery(index, this)[0]: null});};container.bind("activate", activateHandler);return container.bind(settings.event, clickHandler)},activate: function(index) {return this.trigger('activate', [index]);}});jQuery.Accordion = {};jQuery.extend(jQuery.Accordion, {defaults: {selectedClass: "selected",showSpeed: 'fast',hideSpeed: 'fast',alwaysOpen: true,animated: true,event: "click"}});

/*ScrollTo 1.3.2*/
;(function($){var o=$.scrollTo=function(a,b,c){o.window().scrollTo(a,b,c)};o.defaults={axis:'y',duration:1};o.window=function(){return $($.browser.safari?'body':'html')};$.fn.scrollTo=function(l,m,n){if(typeof m=='object'){n=m;m=0}n=$.extend({},o.defaults,n);m=m||n.speed||n.duration;n.queue=n.queue&&n.axis.length>1;if(n.queue)m/=2;n.offset=j(n.offset);n.over=j(n.over);return this.each(function(){var a=this,b=$(a),t=l,c,d={},w=b.is('html,body');switch(typeof t){case'number':case'string':if(/^([+-]=)?\d+(px)?$/.test(t)){t=j(t);break}t=$(t,this);case'object':if(t.is||t.style)c=(t=$(t)).offset()}$.each(n.axis.split(''),function(i,f){var P=f=='x'?'Left':'Top',p=P.toLowerCase(),k='scroll'+P,e=a[k],D=f=='x'?'Width':'Height';if(c){d[k]=c[p]+(w?0:e-b.offset()[p]);if(n.margin){d[k]-=parseInt(t.css('margin'+P))||0;d[k]-=parseInt(t.css('border'+P+'Width'))||0}d[k]+=n.offset[p]||0;if(n.over[p])d[k]+=t[D.toLowerCase()]()*n.over[p]}else d[k]=t[p];if(/^\d+$/.test(d[k]))d[k]=d[k]<=0?0:Math.min(d[k],h(D));if(!i&&n.queue){if(e!=d[k])g(n.onAfterFirst);delete d[k]}});g(n.onAfter);function g(a){b.animate(d,m,n.easing,a&&function(){a.call(this,l)})};function h(D){var b=w?$.browser.opera?document.body:document.documentElement:a;return b['scroll'+D]-b['client'+D]}})};function j(a){return typeof a=='object'?a:{top:a,left:a}}})(jQuery);
;(function($){var a='serialScroll',b='.'+a,c='bind',B=$[a]=function(b){$.scrollTo.window()[a](b)};B.defaults={duration:1e3,axis:'x',event:'click',start:0,step:1,lock:1,cycle:1,constant:1};$.fn[a]=function(x){x=$.extend({},B.defaults,x);var y=x.event,z=x.step,A=x.lazy;return this.each(function(){var j=x.target?this:document,k=$(x.target||this,j),l=k[0],m=x.items,n=x.start,o=x.interval,p=x.navigation,q;if(!A)m=v();if(x.force)s({},n);$(x.prev||[],j)[c](y,-z,r);$(x.next||[],j)[c](y,z,r);if(!l.ssbound)k[c]('prev'+b,-z,r)[c]('next'+b,z,r)[c]('goto'+b,s);if(o)k[c]('start'+b,function(e){if(!o){u();o=1;t()}})[c]('stop'+b,function(){u();o=0});k[c]('notify'+b,function(e,a){var i=w(a);if(i>-1)n=i});l.ssbound=1;if(x.jump)(A?k:v())[c](y,function(e){s(e,w(e.target))});if(p)p=$(p,j)[c](y,function(e){e.data=Math.round(v().length/p.length)*p.index(this);s(e,this)});function r(e){e.data+=n;s(e,this)};function s(e,a){if(!isNaN(a)){e.data=a;a=l}var c=e.data,d,f=e.type,g=v(),h=g.length,i=x.duration;if(f)e.preventDefault();c%=h;if(c<0)c+=h;d=g[c];if(o){u();q=setTimeout(t,x.interval)}if(isNaN(c)||f&&n==c||x.lock&&k.is(':animated')||!x.cycle&&!g[e.data]||f&&x.onBefore&&x.onBefore.call(a,e,d,k,g,c)===!1)return;if(x.stop)k.queue('fx',[]).stop();if(x.constant)i=Math.abs(i/z*(n-c));k.scrollTo(d,i,x).trigger('notify'+b,[c])};function t(){k.trigger('next'+b)};function u(){clearTimeout(q)};function v(){return $(m,k)};function w(a){if(!isNaN(a))return a;var b=v(),i;while((i=b.index(a))==-1&&a!=l)a=a.parentNode;return i}})}})(jQuery);

/*THICKBOX 3.1*/
var tb_pathToImage = "http://www.laestrella.com.pa/images/v2/btns/ajax-loader.gif";function tb_init(domChunk){$(domChunk).click(function(){var t = this.title || this.name || null;var a = this.href || this.alt;var g = this.rel || false;tb_show(t,a,g);this.blur();if($.browser.msie) $("select, object").hide();if($.browser.mozilla ) $(".FS_control").hide();return false;});}function tb_show(caption, url, imageGroup) {try {if (typeof document.body.style.maxHeight === "undefined") {$("body","html").css({height: "100%", width: "100%"});$("html").css("overflow","hidden");if (document.getElementById("TB_HideSelect") === null) {$("body").append("<iframe id='TB_HideSelect'></iframe><div id='TB_overlay'></div><div id='TB_window'></div>");$("#TB_overlay").click(tb_remove);}}else{if(document.getElementById("TB_overlay") === null){$("body").append("<div id='TB_overlay'></div><div id='TB_window'></div>");$("#TB_overlay").click(tb_remove);}}if(tb_detectMacXFF()){$("#TB_overlay").addClass("TB_overlayMacFFBGHack");}else{$("#TB_overlay").addClass("TB_overlayBG");}if(caption===null){caption="";}$("body").append("<div id='TB_load'><img src='"+imgLoader.src+"' /></div>");$('#TB_load').show();var baseURL;if(url.indexOf("?")!==-1){baseURL = url.substr(0, url.indexOf("?"));}else{ baseURL = url;}	   var urlString = /\.jpg$|\.jpeg$|\.png$|\.gif$|\.bmp$/;var urlType = baseURL.toLowerCase().match(urlString);if(urlType == '.jpg' || urlType == '.jpeg' || urlType == '.png' || urlType == '.gif' || urlType == '.bmp'){	TB_PrevCaption = "";TB_PrevURL = "";TB_PrevHTML = "";TB_NextCaption = "";TB_NextURL = "";TB_NextHTML = "";TB_imageCount = "";TB_FoundURL = false;if(imageGroup){TB_TempArray = $("a[@rel="+imageGroup+"]").get();for (TB_Counter = 0; ((TB_Counter < TB_TempArray.length) && (TB_NextHTML === "")); TB_Counter++) {var urlTypeTemp = TB_TempArray[TB_Counter].href.toLowerCase().match(urlString);if (!(TB_TempArray[TB_Counter].href == url)) {if (TB_FoundURL) {TB_NextCaption = TB_TempArray[TB_Counter].title;TB_NextURL = TB_TempArray[TB_Counter].href;TB_NextHTML = "<span id='TB_next' class='tb_btnnext'>&nbsp;&nbsp;<a href='#'><img src='../../../../../images/varios/tbNext.gif' /></a></span>";} else {TB_PrevCaption = TB_TempArray[TB_Counter].title;TB_PrevURL = TB_TempArray[TB_Counter].href;TB_PrevHTML = "<span id='TB_prev' class='tb_btnprev'>&nbsp;&nbsp;<a href='#'><img src='../../../../../images/varios/tbPrev.gif' /></a></span>";}} else {TB_FoundURL = true;TB_imageCount = "<span class='tb_bgpage'>" + (TB_Counter + 1) +" of "+ (TB_TempArray.length)+"</span>";}}}imgPreloader = new Image();imgPreloader.onload = function(){imgPreloader.onload = null;var pagesize = tb_getPageSize();var x = pagesize[0] - 150;var y = pagesize[1] - 150;var imageWidth = imgPreloader.width;var imageHeight = imgPreloader.height;if (imageWidth > x) {imageHeight = imageHeight * (x / imageWidth); imageWidth = x; if (imageHeight > y) { imageWidth = imageWidth * (y / imageHeight); imageHeight = y; }} else if (imageHeight > y) { imageWidth = imageWidth * (y / imageHeight); imageHeight = y; if (imageWidth > x) { imageHeight = imageHeight * (x / imageWidth); imageWidth = x;}}TB_WIDTH = imageWidth + 30;TB_HEIGHT = imageHeight + 60;$("#TB_window").append("<a href='' id='TB_ImageOff' title='Close'><img id='TB_Image' src='"+url+"' width='"+imageWidth+"' height='"+imageHeight+"' alt='"+caption+"'/></a>" + "<div id='TB_caption' class='mBot15'>"+caption+"<div id='TB_secondLine'>" + TB_PrevHTML + TB_imageCount + TB_NextHTML + "</div></div><div id='TB_closeWindow'><a href='#' id='TB_closeWindowButton' title='Close'><img src='../../../../../images/btns/btn_close.gif' /></a></div>"); 					
$("#TB_closeWindowButton").click(tb_remove);if (!(TB_PrevHTML === "")) {function goPrev(){if($(document).unbind("click",goPrev)){$(document).unbind("click",goPrev);}$("#TB_window").remove();$("body").append("<div id='TB_window'></div>");tb_show(TB_PrevCaption, TB_PrevURL, imageGroup);return false;}$("#TB_prev").click(goPrev);}if (!(TB_NextHTML === "")) {	function goNext(){$("#TB_window").remove();$("body").append("<div id='TB_window'></div>");tb_show(TB_NextCaption, TB_NextURL, imageGroup);return false;}$("#TB_next").click(goNext);}document.onkeydown = function(e){ if (e == null) {keycode = event.keyCode;} else {keycode = e.which;}if(keycode == 27){
tb_remove();} else if(keycode == 190){if(!(TB_NextHTML == "")){document.onkeydown = "";goNext();}} else if(keycode == 188){if(!(TB_PrevHTML == "")){document.onkeydown = "";goPrev();}}	};tb_position();$("#TB_load").remove();$("#TB_ImageOff").click(tb_remove);$("#TB_window").css({display:"block"}); };imgPreloader.src = url;}else{var queryString = url.replace(/^[^\?]+\??/,'');var params = tb_parseQuery( queryString );TB_WIDTH = (params['width']*1) + 30 || 630;TB_HEIGHT = (params['height']*1) + 40 || 440;ajaxContentW = TB_WIDTH - 30;ajaxContentH = TB_HEIGHT - 45;if(url.indexOf('TB_iframe') != -1){urlNoQuery = url.split('TB_');$("#TB_iframeContent").remove();if(params['modal'] != "true"){$("#TB_window").append("<div id='TB_title'><div id='TB_ajaxWindowTitle'>"+caption+"</div><div id='TB_closeAjaxWindow'><a href='#' id='TB_closeWindowButton' title='Close'><img src='../../../../../images/v2/btns/btn_cerrar.gif' /></a></div></div><iframe frameborder='0' hspace='0' src='"+urlNoQuery[0]+"' id='TB_iframeContent' name='TB_iframeContent"+Math.round(Math.random()*1000)+"' onload='tb_showIframe()' style='width:"+(ajaxContentW + 29)+"px;height:"+(ajaxContentH + 17)+"px;' > </iframe>");}else{$("#TB_overlay").unbind();$("#TB_window").append("<iframe frameborder='0' hspace='0' src='"+urlNoQuery[0]+"' id='TB_iframeContent' name='TB_iframeContent"+Math.round(Math.random()*1000)+"' onload='tb_showIframe()' style='width:"+(ajaxContentW + 29)+"px;height:"+(ajaxContentH + 17)+"px;'> </iframe>");}}else{if($("#TB_window").css("display") != "block"){
if(params['modal'] != "true"){$("#TB_window").append("<div id='TB_title'><div id='TB_ajaxWindowTitle'>"+caption+"</div><div id='TB_closeAjaxWindow'><a href='#' id='TB_closeWindowButton'><img src='../../../../../images/v2/btns/btn_close.gif' /></a></div></div><div id='TB_ajaxContent' style='width:"+ajaxContentW+"px;height:"+ajaxContentH+"px'></div>");}else{$("#TB_overlay").unbind();$("#TB_window").append("<div id='TB_ajaxContent' class='TB_modal' style='width:"+ajaxContentW+"px;height:"+ajaxContentH+"px;'></div>");	}}else{$("#TB_ajaxContent")[0].style.width = ajaxContentW +"px";$("#TB_ajaxContent")[0].style.height = ajaxContentH +"px";$("#TB_ajaxContent")[0].scrollTop = 0;$("#TB_ajaxWindowTitle").html(caption);}}		$("#TB_closeWindowButton").click(tb_remove);		if(url.indexOf('TB_inline') != -1){	$("#TB_ajaxContent").append($('#' + params['inlineId']).children());$("#TB_window").unload(function () {$('#' + params['inlineId']).append( $("#TB_ajaxContent").children() );});tb_position();$("#TB_load").remove();$("#TB_window").css({display:"block"}); }else if(url.indexOf('TB_iframe') != -1){tb_position();if($.browser.safari){$("#TB_load").remove();$("#TB_window").css({display:"block"});}}else{$("#TB_ajaxContent").load(url += "&random=" + (new Date().getTime()),function(){tb_position();$("#TB_load").remove();tb_init("#TB_ajaxContent a.thickbox");$("#TB_window").css({display:"block"});});}		}if(!params['modal']){document.onkeyup = function(e){ 	if (e == null) {keycode = event.keyCode;} else {keycode = e.which;}if(keycode == 27){tb_remove();}	};}} catch(e) {}}function tb_showIframe(){$("#TB_load").remove();$("#TB_window").css({display:"block"});}function tb_remove() {$("#TB_imageOff").unbind("click");$("#TB_closeWindowButton").unbind("click");$("#TB_window").fadeOut("fast",function(){$('#TB_window,#TB_overlay,#TB_HideSelect').trigger("unload").unbind().remove();});$("#TB_load").remove();if (typeof document.body.style.maxHeight == "undefined") {$("body","html").css({height: "auto", width: "auto"});$("html").css("overflow","");}document.onkeydown = "";document.onkeyup = "";if($.browser.msie) $("select, object").show();if($.browser.mozilla ) $(".FS_control").show();return false;}function tb_position() {$("#TB_window").css({marginLeft: '-' + parseInt((TB_WIDTH / 2),10) + 'px', width: TB_WIDTH + 'px'});if ( !(jQuery.browser.msie && jQuery.browser.version < 7)) {$("#TB_window").css({marginTop: '-' + parseInt((TB_HEIGHT / 2),10) + 'px'});}}function tb_parseQuery ( query ) {var Params = {};if ( ! query ) {return Params;}var Pairs = query.split(/[;&]/);for ( var i = 0; i < Pairs.length; i++ ) {var KeyVal = Pairs[i].split('=');if ( ! KeyVal || KeyVal.length != 2 ) {continue;}var key = unescape( KeyVal[0] );var val = unescape( KeyVal[1] );val = val.replace(/\+/g, ' ');Params[key] = val;}return Params;}function tb_getPageSize(){var de = document.documentElement;var w = window.innerWidth || self.innerWidth || (de&&de.clientWidth) || document.body.clientWidth;var h = window.innerHeight || self.innerHeight || (de&&de.clientHeight) || document.body.clientHeight;arrayPageSize = [w,h];return arrayPageSize;}function tb_detectMacXFF() {var userAgent = navigator.userAgent.toLowerCase();if (userAgent.indexOf('mac') != -1 && userAgent.indexOf('firefox')!=-1) {return true;}}

/* // STYLESWICTH //*/
function setActiveStyleSheet(title) {var i, a, main;for(i=0; (a = document.getElementsByTagName("link")[i]); i++) {if(a.getAttribute("rel").indexOf("style") != -1 && a.getAttribute("title")) {a.disabled = true;if(a.getAttribute("title") == title) a.disabled = false;}}}
function getActiveStyleSheet() {var i, a;for(i=0; (a = document.getElementsByTagName("link")[i]); i++) {if(a.getAttribute("rel").indexOf("style") != -1 && a.getAttribute("title") && !a.disabled) return a.getAttribute("title");
}return null;}
function getPreferredStyleSheet() {var i, a;for(i=0; (a = document.getElementsByTagName("link")[i]); i++) {if(a.getAttribute("rel").indexOf("style") != -1 && a.getAttribute("rel").indexOf("alt") == -1 && a.getAttribute("title")) return a.getAttribute("title");}return null;}

/*pngFix: 1.1*/
(function($) {jQuery.fn.pngFix = function(settings) {settings = jQuery.extend({blankgif: 'blank.gif'}, settings);var ie55 = (navigator.appName == "Microsoft Internet Explorer" && parseInt(navigator.appVersion) == 4 && navigator.appVersion.indexOf("MSIE 5.5") != -1);var ie6 = (navigator.appName == "Microsoft Internet Explorer" && parseInt(navigator.appVersion) == 4 && navigator.appVersion.indexOf("MSIE 6.0") != -1);if (jQuery.browser.msie && (ie55 || ie6)) {jQuery(this).find("img[@src$=.png]").each(function() {jQuery(this).attr('width',jQuery(this).width());jQuery(this).attr('height',jQuery(this).height());var prevStyle = '';var strNewHTML = '';var imgId = (jQuery(this).attr('id')) ? 'id="' + jQuery(this).attr('id') + '" ' : '';var imgClass = (jQuery(this).attr('class')) ? 'class="' + jQuery(this).attr('class') + '" ' : '';var imgTitle = (jQuery(this).attr('title')) ? 'title="' + jQuery(this).attr('title') + '" ' : '';var imgAlt = (jQuery(this).attr('alt')) ? 'alt="' + jQuery(this).attr('alt') + '" ' : '';var imgAlign = (jQuery(this).attr('align')) ? 'float:' + jQuery(this).attr('align') + ';' : '';var imgHand = (jQuery(this).parent().attr('href')) ? 'cursor:hand;' : '';if (this.style.border) {prevStyle += 'border:'+this.style.border+';';this.style.border = '';}if (this.style.padding) {prevStyle += 'padding:'+this.style.padding+';';this.style.padding = '';}if (this.style.margin) {prevStyle += 'margin:'+this.style.margin+';';this.style.margin = '';}var imgStyle = (this.style.cssText);strNewHTML += '<span '+imgId+imgClass+imgTitle+imgAlt;strNewHTML += 'style="position:relative;white-space:pre-line;display:inline-block;background:transparent;'+imgAlign+imgHand;strNewHTML += 'width:' + jQuery(this).width() + 'px;' + 'height:' + jQuery(this).height() + 'px;';strNewHTML += 'filter:progid:DXImageTransform.Microsoft.AlphaImageLoader' + '(src=\'' + jQuery(this).attr('src') + '\', sizingMethod=\'scale\');';strNewHTML += imgStyle+'"></span>';if (prevStyle != ''){strNewHTML = '<span style="position:relative;display:inline-block;'+prevStyle+imgHand+'width:' + jQuery(this).width() + 'px;' + 'height:' + jQuery(this).height() + 'px;'+'">' + strNewHTML + '</span>';}jQuery(this).hide();jQuery(this).after(strNewHTML);});jQuery(this).find("*").each(function(){var bgIMG = jQuery(this).css('background-image');if(bgIMG.indexOf(".png")!=-1){var iebg = bgIMG.split('url("')[1].split('")')[0];jQuery(this).css('background-image', 'none');jQuery(this).get(0).runtimeStyle.filter = "progid:DXImageTransform.Microsoft.AlphaImageLoader(src='" + iebg + "',sizingMethod='scale')";}});jQuery(this).find("input[@src$=.png]").each(function() {var bgIMG = jQuery(this).attr('src');jQuery(this).get(0).runtimeStyle.filter = 'progid:DXImageTransform.Microsoft.AlphaImageLoader' + '(src=\'' + bgIMG + '\', sizingMethod=\'scale\');';jQuery(this).attr('src', settings.blankgif)});}	return jQuery;};})(jQuery);


/* jCarousel 0.2.3*/
(function($) {$.fn.jcarousel = function(o) {return this.each(function() {new $jc(this, o);});};var defaults = {vertical: false,start: 1,offset: 1,size: null,scroll: 3,visible: null,animation: 'normal',easing: 'swing',auto: 0,wrap: 'last',initCallback: null,reloadCallback: null,itemLoadCallback: null,itemFirstInCallback: null,itemFirstOutCallback: null,itemLastInCallback: null,itemLastOutCallback: null,itemVisibleInCallback: null,itemVisibleOutCallback: null,buttonNextHTML: '<div></div>',buttonPrevHTML: '<div></div>',buttonNextEvent: 'click',buttonPrevEvent: 'click',buttonNextCallback: null,buttonPrevCallback: null};$.jcarousel = function(e, o) {this.options    = $.extend({}, defaults, o || {});this.locked     = false;this.container  = null;this.clip       = null;this.list       = null;this.buttonNext = null;this.buttonPrev = null;this.wh = !this.options.vertical ? 'width' : 'height';this.lt = !this.options.vertical ? 'left' : 'top';var skin = '', split = e.className.split(' ');for (var i = 0; i < split.length; i++) {if (split[i].indexOf('jcarousel-skin') != -1) {$(e).removeClass(split[i]);var skin = split[i];break;}}if (e.nodeName == 'UL' || e.nodeName == 'OL') {this.list = $(e);this.container = this.list.parent();if (this.container.hasClass('jcarousel-clip')) {if (!this.container.parent().hasClass('jcarousel-container'))this.container = this.container.wrap('<div></div>');this.container = this.container.parent();} else if (!this.container.hasClass('jcarousel-container'))this.container = this.list.wrap('<div></div>').parent();} else {this.container = $(e);this.list = $(e).find('>ul,>ol,div>ul,div>ol');}if (skin != '' && this.container.parent()[0].className.indexOf('jcarousel-skin') == -1)this.container.wrap('<div class=" '+ skin + '"></div>');this.clip = this.list.parent();if (!this.clip.length || !this.clip.hasClass('jcarousel-clip'))this.clip = this.list.wrap('<div></div>').parent();this.buttonPrev = $('.jcarousel-prev', this.container);if (this.buttonPrev.size() == 0 && this.options.buttonPrevHTML != null)this.buttonPrev = this.clip.before(this.options.buttonPrevHTML).prev();this.buttonPrev.addClass(this.className('jcarousel-prev'));this.buttonNext = $('.jcarousel-next', this.container);if (this.buttonNext.size() == 0 && this.options.buttonNextHTML != null)this.buttonNext = this.clip.before(this.options.buttonNextHTML).prev();this.buttonNext.addClass(this.className('jcarousel-next'));this.clip.addClass(this.className('jcarousel-clip'));this.list.addClass(this.className('jcarousel-list'));this.container.addClass(this.className('jcarousel-container'));var di = this.options.visible != null ? Math.ceil(this.clipping() / this.options.visible) : null;var li = this.list.children('li');var self = this;if (li.size() > 0) {var wh = 0, i = this.options.offset;li.each(function() {self.format(this, i++);wh += self.dimension(this, di);});this.list.css(this.wh, wh + 'px');if (!o || o.size === undefined)this.options.size = li.size();}this.container.css('display', 'block');this.buttonNext.css('display', 'block');this.buttonPrev.css('display', 'block');this.funcNext   = function() { self.next(); };this.funcPrev   = function() { self.prev(); };this.funcResize = function() { self.prev(); };if (this.options.initCallback != null)this.options.initCallback(this, 'init');if ($.browser.safari) {this.buttons(false, false);$(window).bind('load', function() { self.setup(); });} else this.setup();};var $jc = $.jcarousel;$jc.fn = $jc.prototype = {jcarousel: '0.2.3'};$jc.fn.extend = $jc.extend = $.extend;$jc.fn.extend({setup: function() {this.first     = null;this.last      = null;this.prevFirst = null;this.prevLast  = null;this.animating = false;this.timer     = null;this.tail      = null;this.inTail    = false;if (this.locked)return;this.list.css(this.lt, this.pos(this.options.offset) + 'px');var p = this.pos(this.options.start);this.prevFirst = this.prevLast = null;this.animate(p, false);$(window).unbind('resize', this.funcResize).bind('resize', this.funcResize);},reset: function() {this.list.empty();this.list.css(this.lt, '0px');this.list.css(this.wh, '10px');if (this.options.initCallback != null)this.options.initCallback(this, 'reset');this.setup();},reload: function() {if (this.tail != null && this.inTail)this.list.css(this.lt, $jc.intval(this.list.css(this.lt)) + this.tail);this.tail   = null;this.inTail = false;if (this.options.reloadCallback != null)this.options.reloadCallback(this);if (this.options.visible != null) {var self = this;var di = Math.ceil(this.clipping() / this.options.visible), wh = 0, lt = 0;$('li', this.list).each(function(i) {wh += self.dimension(this, di);if (i + 1 < self.first)lt = wh;});this.list.css(this.wh, wh + 'px');this.list.css(this.lt, -lt + 'px');}this.scroll(this.first, false);},lock: function() {this.locked = true;this.buttons();},unlock: function() {this.locked = false;this.buttons();},size: function(s) {if (s != undefined) {this.options.size = s;if (!this.locked)this.buttons();}return this.options.size;},has: function(i, i2) {if (i2 == undefined || !i2)i2 = i;if (this.options.size !== null && i2 > this.options.size)i2 = this.options.size;for (var j = i; j <= i2; j++) {var e = this.get(j);if (!e.length || e.hasClass('jcarousel-item-placeholder'))return false;}return true;},get: function(i) {return $('.jcarousel-item-' + i, this.list);},add: function(i, s) {var e = this.get(i), old = 0, add = 0;if (e.length == 0) {var c, e = this.create(i), j = $jc.intval(i);while (c = this.get(--j)) {if (j <= 0 || c.length) {j <= 0 ? this.list.prepend(e) : c.after(e);break;}}} else old = this.dimension(e);e.removeClass(this.className('jcarousel-item-placeholder'));typeof s == 'string' ? e.html(s) : e.empty().append(s);var di = this.options.visible != null ? Math.ceil(this.clipping() / this.options.visible) : null;var wh = this.dimension(e, di) - old;if (i > 0 && i < this.first)this.list.css(this.lt, $jc.intval(this.list.css(this.lt)) - wh + 'px');this.list.css(this.wh, $jc.intval(this.list.css(this.wh)) + wh + 'px');return e;},remove: function(i) {var e = this.get(i);if (!e.length || (i >= this.first && i <= this.last))return;var d = this.dimension(e);if (i < this.first)this.list.css(this.lt, $jc.intval(this.list.css(this.lt)) + d + 'px');e.remove();this.list.css(this.wh, $jc.intval(this.list.css(this.wh)) - d + 'px');},next: function() {this.stopAuto();if (this.tail != null && !this.inTail)this.scrollTail(false);else this.scroll(((this.options.wrap == 'both' || this.options.wrap == 'last') && this.options.size != null && this.last == this.options.size) ? 1 : this.first + this.options.scroll);},prev: function() {this.stopAuto();if (this.tail != null && this.inTail)this.scrollTail(true);else this.scroll(((this.options.wrap == 'both' || this.options.wrap == 'first') && this.options.size != null && this.first == 1) ? this.options.size : this.first - this.options.scroll);},scrollTail: function(b) {if (this.locked || this.animating || !this.tail)return;var pos  = $jc.intval(this.list.css(this.lt));!b ? pos -= this.tail : pos += this.tail;this.inTail = !b;this.prevFirst = this.first;this.prevLast  = this.last;this.animate(pos);},scroll: function(i, a) {if (this.locked || this.animating)return;this.animate(this.pos(i), a);},pos: function(i) {if (this.locked || this.animating)return;if (this.options.wrap != 'circular')i = i < 1 ? 1 : (this.options.size && i > this.options.size ? this.options.size : i);var back = this.first > i;var pos  = $jc.intval(this.list.css(this.lt));var f = this.options.wrap != 'circular' && this.first <= 1 ? 1 : this.first;var c = back ? this.get(f) : this.get(this.last);var j = back ? f : f - 1;var e = null, l = 0, p = false, d = 0;while (back ? --j >= i : ++j < i) {e = this.get(j);p = !e.length;if (e.length == 0) {e = this.create(j).addClass(this.className('jcarousel-item-placeholder'));c[back ? 'before' : 'after' ](e);}c = e;d = this.dimension(e);if (p)l += d;if (this.first != null && (this.options.wrap == 'circular' || (j >= 1 && (this.options.size == null || j <= this.options.size))))pos = back ? pos + d : pos - d;}var clipping = this.clipping();var cache = [];var visible = 0, j = i, v = 0;var c = this.get(i - 1);while (++visible) {e = this.get(j);p = !e.length;if (e.length == 0) {e = this.create(j).addClass(this.className('jcarousel-item-placeholder'));c.length == 0 ? this.list.prepend(e) : c[back ? 'before' : 'after' ](e);}c = e;var d = this.dimension(e);if (d == 0) {alert('jCarousel: No width/height set for items. This will cause an infinite loop. Aborting...');return 0;}if (this.options.wrap != 'circular' && this.options.size !== null && j > this.options.size)cache.push(e);else if (p)l += d;v += d;if (v >= clipping)break;j++;}for (var x = 0; x < cache.length; x++)cache[x].remove();if (l > 0) {this.list.css(this.wh, this.dimension(this.list) + l + 'px');if (back) {pos -= l;this.list.css(this.lt, $jc.intval(this.list.css(this.lt)) - l + 'px');}}var last = i + visible - 1;if (this.options.wrap != 'circular' && this.options.size && last > this.options.size)last = this.options.size;if (j > last) {visible = 0, j = last, v = 0;while (++visible) {var e = this.get(j--);if (!e.length)break;v += this.dimension(e);if (v >= clipping)break;}}var first = last - visible + 1;if (this.options.wrap != 'circular' && first < 1)first = 1;if (this.inTail && back) {pos += this.tail;this.inTail = false;}this.tail = null;if (this.options.wrap != 'circular' && last == this.options.size && (last - visible + 1) >= 1) {var m = $jc.margin(this.get(last), !this.options.vertical ? 'marginRight' : 'marginBottom');if ((v - m) > clipping)this.tail = v - clipping - m;}while (i-- > first)pos += this.dimension(this.get(i));this.prevFirst = this.first;this.prevLast  = this.last;this.first     = first;this.last      = last;return pos;},animate: function(p, a) {if (this.locked || this.animating)return;this.animating = true;var self = this;var scrolled = function() {self.animating = false;if (p == 0)self.list.css(self.lt,  0);if (self.options.wrap == 'both' || self.options.wrap == 'last' || self.options.size == null || self.last < self.options.size)self.startAuto();self.buttons();self.notify('onAfterAnimation');};this.notify('onBeforeAnimation');if (!this.options.animation || a == false) {this.list.css(this.lt, p + 'px');scrolled();} else {var o = !this.options.vertical ? {'left': p} : {'top': p};this.list.animate(o, this.options.animation, this.options.easing, scrolled);}},startAuto: function(s) {if (s != undefined)this.options.auto = s;if (this.options.auto == 0)return this.stopAuto();if (this.timer != null)return;var self = this;this.timer = setTimeout(function() { self.next(); }, this.options.auto * 1000);},stopAuto: function() {if (this.timer == null)return;clearTimeout(this.timer);this.timer = null;},buttons: function(n, p) {if (n == undefined || n == null) {var n = !this.locked && this.options.size !== 0 && ((this.options.wrap && this.options.wrap != 'first') || this.options.size == null || this.last < this.options.size);if (!this.locked && (!this.options.wrap || this.options.wrap == 'first') && this.options.size != null && this.last >= this.options.size)n = this.tail != null && !this.inTail;}if (p == undefined || p == null) {var p = !this.locked && this.options.size !== 0 && ((this.options.wrap && this.options.wrap != 'last') || this.first > 1);if (!this.locked && (!this.options.wrap || this.options.wrap == 'last') && this.options.size != null && this.first == 1)p = this.tail != null && this.inTail;}var self = this;this.buttonNext[n ? 'bind' : 'unbind'](this.options.buttonNextEvent, this.funcNext)[n ? 'removeClass' : 'addClass'](this.className('jcarousel-next-disabled')).attr('disabled', n ? false : true);this.buttonPrev[p ? 'bind' : 'unbind'](this.options.buttonPrevEvent, this.funcPrev)[p ? 'removeClass' : 'addClass'](this.className('jcarousel-prev-disabled')).attr('disabled', p ? false : true);if (this.buttonNext.length > 0 && (this.buttonNext[0].jcarouselstate == undefined || this.buttonNext[0].jcarouselstate != n) && this.options.buttonNextCallback != null) {this.buttonNext.each(function() { self.options.buttonNextCallback(self, this, n); });this.buttonNext[0].jcarouselstate = n;}if (this.buttonPrev.length > 0 && (this.buttonPrev[0].jcarouselstate == undefined || this.buttonPrev[0].jcarouselstate != p) && this.options.buttonPrevCallback != null) {this.buttonPrev.each(function() { self.options.buttonPrevCallback(self, this, p); });this.buttonPrev[0].jcarouselstate = p;}},notify: function(evt) {var state = this.prevFirst == null ? 'init' : (this.prevFirst < this.first ? 'next' : 'prev');this.callback('itemLoadCallback', evt, state);if (this.prevFirst !== this.first) {this.callback('itemFirstInCallback', evt, state, this.first);this.callback('itemFirstOutCallback', evt, state, this.prevFirst);}if (this.prevLast !== this.last) {this.callback('itemLastInCallback', evt, state, this.last);this.callback('itemLastOutCallback', evt, state, this.prevLast);}this.callback('itemVisibleInCallback', evt, state, this.first, this.last, this.prevFirst, this.prevLast);this.callback('itemVisibleOutCallback', evt, state, this.prevFirst, this.prevLast, this.first, this.last);},callback: function(cb, evt, state, i1, i2, i3, i4) {if (this.options[cb] == undefined || (typeof this.options[cb] != 'object' && evt != 'onAfterAnimation'))return;var callback = typeof this.options[cb] == 'object' ? this.options[cb][evt] : this.options[cb];if (!$.isFunction(callback))return;var self = this;if (i1 === undefined)callback(self, state, evt);else if (i2 === undefined)this.get(i1).each(function() { callback(self, this, i1, state, evt); });else {for (var i = i1; i <= i2; i++)if (i !== null && !(i >= i3 && i <= i4))this.get(i).each(function() { callback(self, this, i, state, evt); });}},create: function(i) {return this.format('<li></li>', i);},format: function(e, i) {var $e = $(e).addClass(this.className('jcarousel-item')).addClass(this.className('jcarousel-item-' + i));$e.attr('jcarouselindex', i);return $e;},className: function(c) {return c + ' ' + c + (!this.options.vertical ? '-horizontal' : '-vertical');},dimension: function(e, d) {var el = e.jquery != undefined ? e[0] : e;var old = !this.options.vertical ? el.offsetWidth + $jc.margin(el, 'marginLeft') + $jc.margin(el, 'marginRight') : el.offsetHeight + $jc.margin(el, 'marginTop') + $jc.margin(el, 'marginBottom');if (d == undefined || old == d)return old;var w = !this.options.vertical ? d - $jc.margin(el, 'marginLeft') - $jc.margin(el, 'marginRight') : d - $jc.margin(el, 'marginTop') - $jc.margin(el, 'marginBottom');$(el).css(this.wh, w + 'px');return this.dimension(el);},clipping: function() {return !this.options.vertical ? this.clip[0].offsetWidth - $jc.intval(this.clip.css('borderLeftWidth')) - $jc.intval(this.clip.css('borderRightWidth')) : this.clip[0].offsetHeight - $jc.intval(this.clip.css('borderTopWidth')) - $jc.intval(this.clip.css('borderBottomWidth'));},index: function(i, s) {if (s == undefined)s = this.options.size;return Math.round((((i-1) / s) - Math.floor((i-1) / s)) * s) + 1;}});$jc.extend({defaults: function(d) {return $.extend(defaults, d || {});},margin: function(e, p) {if (!e)return 0;var el = e.jquery != undefined ? e[0] : e;if (p == 'marginRight' && $.browser.safari) {var old = {'display': 'block', 'float': 'none', 'width': 'auto'}, oWidth, oWidth2;$.swap(el, old, function() { oWidth = el.offsetWidth; });old['marginRight'] = 0;$.swap(el, old, function() { oWidth2 = el.offsetWidth; });return oWidth2 - oWidth;}return $jc.intval($.css(el, p));},intval: function(v) {v = parseInt(v);return isNaN(v) ? 0 : v;}});})(jQuery);

/* // swf object change //*/
function sendEventV(typ,prm) { thisMovie("player_video").sendEvent(typ,prm); };
function sendEventA(typ,prm) { thisMovie("player_audio").sendEvent(typ,prm); };
function thisMovie(movieName) {	if(navigator.appName.indexOf("Microsoft") != -1) {	return window[movieName]; 	} else {	return document[movieName];	}};

function swf_video(name_video,titulo_video , descrip_video) {
	var s1 = new SWFObject("http://www.laestrella.com.pa/swf/mediaplayer.swf","player_video","306","232","7");
	s1.addParam("allowfullscreen","true");
	s1.addParam("wmode","opaque");
	s1.addParam("bufferlength","30");
	s1.addVariable("file",name_video);
	s1.addVariable("logo","http://www.laestrella.com.pa/swf/logo.png");
	s1.addVariable("skin","metarby10");
	s1.addVariable("enablejs","true");
	s1.addVariable("javascriptid","player_video");
	s1.addVariable("width","306");
	s1.addVariable("height","230");
	if(name_video == name_flv)
		s1.addVariable("autostart","false");
	else
		s1.addVariable("autostart","true");
	s1.addVariable("image",image_flv);
	s1.addVariable("video_title", titulo_video);
	s1.addVariable("video_content", descrip_video);
	s1.write("playervideo");
};
function swf_video_2(name_video,titulo_video , descrip_video) {
	var s1b = new SWFObject("http://www.laestrella.com.pa/swf/mediaplayer.swf","player_video","320","232","7");
	s1b.addParam("allowfullscreen","true");
	s1b.addParam("wmode","opaque");
	s1b.addParam("bufferlength","30");
	s1b.addVariable("logo","http://www.laestrella.com.pa/swf/logo.png");
	s1b.addVariable("skin","metarby10");
	s1b.addVariable("file",name_video);
	s1b.addVariable("enablejs","true");
	s1b.addVariable("javascriptid","player_video");
	s1b.addVariable("width","320");
	s1b.addVariable("height","240");
	if(name_video == name_flv)
		s1b.addVariable("autostart","false");
	else
		s1b.addVariable("autostart","true");
	s1b.addVariable("image",image_flv);
	s1b.addVariable("video_title", titulo_video);
	s1b.addVariable("video_content", descrip_video);
	s1b.write("playervideo");
};
function swf_video3(name_video,titulo_video , descrip_video) {
	var s1 = new SWFObject("http://www.laestrella.com.pa/swf/mediaplayer.swf","player_video","306","230","7");
	s1.addParam("allowfullscreen","true");
	s1.addParam("wmode","opaque");
	s1.addParam("bufferlength","30");
	s1.addVariable("file",name_video);
	s1.addVariable("logo","http://www.laestrella.com.pa/swf/logo.png");
	s1.addVariable("skin","metarby10");
	s1.addVariable("enablejs","true");
	s1.addVariable("javascriptid","player_video");
	s1.addVariable("width","306");
	s1.addVariable("height","230");
	if(name_video == name_flv)
		s1.addVariable("autostart","false");
	else
		s1.addVariable("autostart","true");
	s1.addVariable("image",image_flv);
	s1.addVariable("video_title", titulo_video);
	s1.addVariable("video_content", descrip_video);
	s1.write("playervideo");
};
//function swf_audio(name_audio){
//	var s2 = new SWFObject('http://www.laestrella.com.pa/swf/mediaplayer.swf','player_audio','300','232','7');
//	s2.addVariable("enablejs","true");
//	s2.addVariable("javascriptid","player_audio");
//	s2.addVariable('width','320');
//	s2.addVariable('height','20');
//	s2.addVariable("autostart","true");
//	s2.addVariable('file',name_audio);
//	s2.addVariable("logo","http://www.laestrella.com.pa/swf/logo.png");
//	s2.write('playeraudio');
//};

function swf_video4(name_video,titulo_video , descrip_video) {
	var s1 = new SWFObject("http://www.laestrella.com.pa/swf/mediaplayer.swf","player_video","306","232","7");
	s1.addParam("allowfullscreen","true");
	s1.addParam("wmode","opaque");
	s1.addParam("bufferlength","30");
	s1.addVariable("file",name_video);
	s1.addVariable("logo","http://www.laestrella.com.pa/swf/logo.png");
	s1.addVariable("skin","metarby10");
	s1.addVariable("enablejs","true");
	s1.addVariable("javascriptid","player_video");
	s1.addVariable("width","306");
	s1.addVariable("height","232");
	if(name_video == name_flv)
		s1.addVariable("autostart","false");
	else
		s1.addVariable("autostart","true");
	s1.addVariable("image",image_flv);
	s1.addVariable("video_title", titulo_video);
	s1.addVariable("video_content", descrip_video);
	s1.write("playervideo");
};

function swf_video5(name_video,titulo_video , descrip_video) {
	var s1 = new SWFObject("http://www.laestrella.com.pa/swf/mediaplayer.swf","player_video","300","232","7");
	s1.addParam("allowfullscreen","true");
	s1.addParam("wmode","opaque");
	s1.addParam("bufferlength","30");
	s1.addVariable("file",name_video);
	s1.addVariable("logo","http://www.laestrella.com.pa/swf/logo.png");
	s1.addVariable("skin","metarby10");
	s1.addVariable("enablejs","true");
	s1.addVariable("javascriptid","player_video");
	s1.addVariable("width","300");
	s1.addVariable("height","232");
	if(name_video == name_flv)
		s1.addVariable("autostart","false");
	else
		s1.addVariable("autostart","true");
	s1.addVariable("image",image_flv);
	s1.addVariable("video_title", titulo_video);
	s1.addVariable("video_content", descrip_video);
	s1.write("playervideo");
};

function swf_video6() {
	var so = new SWFObject('http://www.laestrella.com.pa/swf/player.swf','mpl','306','232','7');
	so.addParam('allowscriptaccess','always');
	so.addParam('allowfullscreen','true');
	so.addParam('flashvars','&file=http://www.laestrella.com.pa/servicios/videos.xml&backcolor=000000&frontcolor=ffffff&playlistsize=230&bufferlength=30&streamer=lighttpd&playlist=over&logo=http://www.laestrella.com.pa/swf/logo.png');
	so.write('playervideo');
};

function swf_video7() {
	var so = new SWFObject('http://www.laestrella.com.pa/swf/player.swf','mpl','300','290','7');
	so.addParam('allowscriptaccess','always');
	so.addParam('allowfullscreen','true');
	so.addParam('flashvars','&file=http://www.laestrella.com.pa/servicios/videos.xml&backcolor=000000&frontcolor=ffffff&playlistsize=230&bufferlength=30&streamer=lighttpd&playlist=over&logo=http://www.laestrella.com.pa/swf/logo.png');
	so.write('playervideo');
};

function swf_slideshow(name_video, titulo_video, descrip_video) {
	var s1 = new SWFObject("http://www.laestrella.com.pa/swf/player.swf","player_video","300","232","7");
	s1.addParam("allowfullscreen","true");
	s1.addParam("wmode","opaque");
	s1.addParam("bufferlength","30");
	s1.addVariable("file",name_video);
	s1.addVariable("logo","http://www.laestrella.com.pa/swf/logo.png");
	s1.addVariable("autostart","true");
	s1.addVariable("javascriptid","slideshow");
	s1.addVariable("video_title", titulo_video);
	s1.addVariable("video_content", descrip_video);
	s1.write("slideshow");
};

function swf_audio(name_audio, titulo_video, descrip_video) {
	var s1 = new SWFObject("http://www.laestrella.com.pa/swf/player.swf","player_video","306","20","7");
	s1.addParam("allowfullscreen","false");
	s1.addParam("wmode","opaque");
	s1.addParam("bufferlength","30");
	s1.addVariable("file",name_audio);
	s1.addVariable("logo","http://www.laestrella.com.pa/swf/logo.png");
	s1.addVariable("autostart","true");
	s1.addVariable("javascriptid","slideshow");
	//s1.addVariable("video_title", titulo_video);
	//s1.addVariable("video_content", descrip_video);
	s1.write("slideshow");
};
