var jQueryScriptOutputted = false; var sliderIntervalId = 0; var sliderHeight = 0; var sliderWidth = 0; var prQuery; var sliding = false; var slideSpeed = 10; var height = '229'; var width = '100%'; var bgColor = '##06F'; var widgetWrapper; function prCreateWidget(){ c = prReadCookie('prHideSliderpr2400'); widgetWrapper = document.createElement('div'); widgetWrapper.id = 'prSliderpr2400'; widgetWrapper.setAttribute('style',"font-family:Tahoma,Geneva,sans-serif;font-size:12px;height:229px;left:0;position:fixed;opacity:0;overflow:hidden;right:0;width:auto;z-index:100000;bottom:-229px;"); widget = document.createElement('div'); widget.id = 'prSliderWidgetpr2400'; widget.setAttribute('style',"height:209px;width:100%;"); lShad = document.createElement('div'); rShad = document.createElement('div'); shad = document.createElement('div'); iframeWrapper = document.createElement('div'); lShad.setAttribute('style',"background-image:url('http://twiant.com/img/slider/colors/lime.png');background-position:9px top;background-repeat:no-repeat;display:inline-block;float:left;height:216px;margin-top:13px;width:25px;"); rShad.setAttribute('style',"background-image:url('http://twiant.com/img/slider/colors/lime.png');background-position:-18px top;background-repeat:no-repeat;display:inline-block;float:right;height:216px;margin-top:13px;width:25px;"); shad.setAttribute('style',"height:7px;margin-top:13px;;"); iframeWrapper.setAttribute('style',"background-image:url('http://twiant.com/img/slider/colors/lime.png');background-position:0 -312px;background-repeat:repeat-x;height:209px;margin:0 25px;margin-top:13px;padding-top:7px;"); closeLink = document.createElement('a'); closeLink.setAttribute('style',"background-image:url('http://twiant.com/img/slider/close_btn.png');background-repeat:no-repeat;color:#FFF;cursor:pointer;display:inline-block;font-weight:bold;height:28px;position:absolute;right:2px;text-decoration:none;width:28px;z-index:100;top:6px;"); closeLink.innerHTML = ' '; closeLink.id = 'prCloseLinkpr2400'; showLink = document.createElement('a'); showLink.id = 'prShowLinkpr2400'; jQuery(showLink).click(function(){prToggle();}); if(c){ showLink.setAttribute('style',"background-image:url('http://twiant.com/img/slider/show_bottom.png');background-repeat:no-repeat;cursor:pointer;display:inline-block;height:28px;position:fixed;right:4px;text-decoration:none;width:28px;z-index:100001;bottom:4px;"); }else{ showLink.setAttribute('style',"background-image:url('http://twiant.com/img/slider/show_bottom.png');background-repeat:no-repeat;cursor:pointer;display:inline-block;height:28px;position:fixed;right:4px;text-decoration:none;width:28px;z-index:100001;bottom:-28px;"); } jQuery(closeLink).click(function(){prToggle();}); iframe = document.createElement('iframe'); iframe.height = 209; iframe.setAttribute('allowtransparency',1); iframe.setAttribute('frameborder',0); iframe.setAttribute('scrolling','no'); iframe.src = 'http://widget.plugrush.com/realgirlspost.com/hi8'; iframe.width = '100%'; widget.appendChild(iframe); iframeWrapper.appendChild(widget); widgetWrapper.appendChild(lShad); widgetWrapper.appendChild(rShad); widgetWrapper.appendChild(iframeWrapper); widgetWrapper.appendChild(closeLink); document.body.appendChild(widgetWrapper); document.body.appendChild(showLink); if(c){ // jQuery('#prShowLinkpr2400').animate({bottom:4},500,'easeInCirc'); }else{ prSlide(2000); } } function prTheSlider(){ if(typeof(jQuery)=='undefined'||jQuery.fn.jquery=='1.2.6'){ if(!jQueryScriptOutputted){ jQueryScriptOutputted = true; script = document.createElement('script'); script.setAttribute('src','http://ajax.googleapis.com/ajax/libs/jquery/1.6.4/jquery.min.js'); document.head.appendChild(script); script = document.createElement('script'); script.setAttribute('src','http://ajax.googleapis.com/ajax/libs/jqueryui/1.8.16/jquery-ui.min.js'); document.head.appendChild(script); script = document.createElement('script'); script.innerHtml = '$.noConflict();'; document.head.appendChild(script); } setTimeout('prTheSlider()',50); }else{ prCreateWidget(); } } function prToggle(){ opacity = jQuery('#prSliderpr2400').css('opacity'); if(opacity==1){ jQuery('#prSliderpr2400').animate({opacity:0,bottom:'-229'},500,'easeInCirc',function(){jQuery('#prShowLinkpr2400').animate({bottom:4},500,'easeOutCirc')}); prCreateCookie('prHideSliderpr2400',1,1); } if(opacity==0){ jQuery('#prSliderpr2400').animate({opacity: 1,bottom:0},500,'easeOutCirc'); jQuery('#prShowLinkpr2400').animate({bottom:-28},500,'easeInCirc'); prDeleteCookie('prHideSliderpr2400'); } } function prSlide(delay){ jQuery('#prSliderpr2400').delay(delay).animate({opacity:1,bottom:0},500,'easeOutCirc'); } function prCreateCookie(name,value,days){ if(days){ var date = new Date(); date.setTime(date.getTime()+(days*24*60*60*1000)); var expires = "; expires="+date.toGMTString(); }else{ var expires = ""; } document.cookie = name+"="+value+expires+"; path=/"; } function prReadCookie(name){ var nameEQ = name+"="; var ca = document.cookie.split(';'); for(var i=0;i