分享一款经典的jquery广告图片切换特效,这几张图片定时切换显示,在图片切换窗口的右下角带图片编号显示。
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=gb2312" /> <meta name="keywords" content="武鸣人网站,武鸣信息网,武鸣本地网,武鸣信息资源平台,减肥,健身,励志,励志语录,js特效,网页特效,www.wuming.ren"> <meta name="description" content="欢迎来到武鸣人信息资源平台,各种信息免费发布,资源共享合作共赢,分享互联网流行的励志语录经典短句,减肥健身健康小常识及打卡记录,收集各种js特效代码。"> <title>五屏jquery广告图片定时切换特效_武鸣人</title> <style type="text/css"> @charset "utf-8"; html{color: #333;background:#f5f6f8;} body,div,dl,dt,dd,ul,ol,li,h1,h2,h3,h4,h5,h6,pre,code,form,fieldset,legend,input,button,textarea,p,blockquote,th,td{margin:0;padding:0;} body,input,select,textarea{font-size:12px;font-family:"微软雅黑", Tahoma, Arial;} img{border:0} ul,li{list-style:none;} #wwwwumingren{width:980px;margin:9px auto 0 auto;height:323px;position:relative;} #wwwwumingren div{float:left;} #wuming{width:576px;height:260px;} .wuming_ren li{background:url(/img/20240419_www_wuming_ren_5.gif) no-repeat;border:0;} .wuming_ren{ position:absolute; right:8px; bottom:8px; font:12px/1.5 tahoma, arial;} .wuming_ren li{color: #fff;padding-left:7px;line-height: 14px;width: 12px;height: 14px;font-family: Arial;font-size: 11px;cursor: pointer;margin-top: 5px;background-position:-482px -32px;font-weight: bold;} .wuming_ren li.on{line-height: 14px;background-position:-482px -10px;font-size: 12px;color:#FFF;} </style> <script type="text/javascript" src="/img/jquery_wuming_ren.js"></script> <script type="text/javascript"> var Speed_1 = 10; //速度(毫秒) var Space_1 = 20; //每次移动(px) var PageWidth_1 = 140 * 3; //翻页宽度 var interval_1 = 7000; //翻页间隔 var fill_1 = 0; //整体移位 //武鸣人网站https://www.wuming.ren 网站很好记住,wuming.ren(武鸣拼音.ren域名后缀) function get_data(service_url,service_para){ if (typeof service_para=='undefined')service_para=''; return eval($.ajax({ url: service_url, type: 'GET', data:service_para, dataType: 'json', timeout: 10000, async:false, error: function(){ alert('失败,请稍后重试!'); } }).responseText); } function random_char(l) { var x="0123456789qwertyuioplkjhgfdsazxcvbnm"; var tmp=""; for(var i=0;i< l;i++) { tmp += x.charAt(Math.ceil(Math.random()*100000000)%x.length); } return tmp; }//武鸣人网站https://www.wuming.ren 网站很好记住,wuming.ren(武鸣拼音.ren域名后缀) function img_roll1(random_str){ this.random_str=random_str; } //三个切换 function GetObj(objName,random_str){ if(document.getElementById){ return eval('document.getElementById("'+objName+'_'+random_str+'");'); }else{ return eval('document.all.'+objName+'_'+random_str); } } function AutoPlay_1(random_str){ eval("clearInterval(AutoPlayObj_"+random_str+");"); eval("AutoPlayObj_"+random_str+"=setInterval('ISL_GoDown_1(\""+random_str+"\");ISL_StopDown_1(\""+random_str+"\");',interval_1);"); } function ISL_GoUp_1(random_str){ if(eval("MoveLock_"+random_str))return; eval("clearInterval(AutoPlayObj_"+random_str+");"); eval("MoveLock_"+random_str+"=true;"); eval("MoveWay_"+random_str+"='left';"); eval("MoveTimeObj_"+random_str+"=setInterval('ISL_ScrUp_1(\""+random_str+"\");',Speed_1);"); }//武鸣人网站https://www.wuming.ren 网站很好记住,wuming.ren(武鸣拼音.ren域名后缀) function ISL_StopUp_1(random_str){ if(eval("MoveWay_"+random_str) == "right")return; eval("clearInterval(MoveTimeObj_"+random_str+");"); if((GetObj('img_roll1',random_str).scrollLeft-fill_1)%PageWidth_1!=0){ eval("Comp_"+random_str+"=fill_1-(GetObj('img_roll1',random_str).scrollLeft%PageWidth_1);"); CompScr_1(random_str); }else{ eval("MoveLock_"+random_str+"=false;"); } AutoPlay_1(random_str); }//武鸣人网站https://www.wuming.ren 网站很好记住,wuming.ren(武鸣拼音.ren域名后缀) function ISL_ScrUp_1(random_str){ if(GetObj('img_roll1',random_str).scrollLeft<=0){ GetObj('img_roll1',random_str).scrollLeft=GetObj('img_roll1',random_str).scrollLeft+GetObj('img_list1',random_str).offsetWidth; } GetObj('img_roll1',random_str).scrollLeft-=Space_1; }//武鸣人网站https://www.wuming.ren 网站很好记住,wuming.ren(武鸣拼音.ren域名后缀) function ISL_GoDown_1(random_str){ //eval("alert(typeof MoveTimeObj_"+random_str+");"); eval("clearInterval(MoveTimeObj_"+random_str+");"); if(eval("MoveLock_"+random_str))return; eval("clearInterval(AutoPlayObj_"+random_str+");"); eval("MoveLock_"+random_str+"=true;"); eval("MoveWay_"+random_str+"='right';"); ISL_ScrDown_1(random_str); eval("MoveTimeObj_"+random_str+"=setInterval('ISL_ScrDown_1(\""+random_str+"\");',Speed_1);"); } function ISL_StopDown_1(random_str){ if(eval("MoveWay_"+random_str) == "left")return; eval("clearInterval(MoveTimeObj_"+random_str+");"); if(GetObj('img_roll1',random_str).scrollLeft%PageWidth_1-(fill_1>=0?fill_1:fill_1+1)!=0){ eval("Comp_"+random_str+"=PageWidth_1-GetObj('img_roll1',random_str).scrollLeft%PageWidth_1+fill_1;"); CompScr_1(random_str); }else{ eval("MoveLock_"+random_str+"=false;"); } AutoPlay_1(random_str); }//武鸣人网站https://www.wuming.ren 网站很好记住,wuming.ren(武鸣拼音.ren域名后缀) function ISL_ScrDown_1(random_str){ if(GetObj('img_roll1',random_str).scrollLeft>=GetObj('img_list1',random_str).scrollWidth){ GetObj('img_roll1',random_str).scrollLeft=GetObj('img_roll1',random_str).scrollLeft-GetObj('img_list1',random_str).scrollWidth; } GetObj('img_roll1',random_str).scrollLeft+=Space_1; } function CompScr_1(random_str){ if(eval("Comp_"+random_str)==0){ eval("MoveLock_"+random_str+"=false;"); return; } var num,TempSpeed=Speed_1,TempSpace=Space_1; if(Math.abs(eval("Comp_"+random_str))<PageWidth_1/2){ TempSpace=Math.round(Math.abs(eval("Comp_"+random_str)/Space_1)); if(TempSpace<1)TempSpace=1; } if(eval("Comp_"+random_str)<0){ if(eval("Comp_"+random_str)<-TempSpace){ eval("Comp_"+random_str+"+=TempSpace;"); num=TempSpace; }else{ eval("num=-Comp_"+random_str+";"); eval("Comp_"+random_str+"=0;"); } GetObj('img_roll1',random_str).scrollLeft-=num; setTimeout('CompScr_1("'+random_str+'")',TempSpeed); }else{ if(eval("Comp_"+random_str)>TempSpace){ eval("Comp_"+random_str+"-=TempSpace;"); num=TempSpace; }else{ num=eval("Comp_"+random_str); eval("Comp_"+random_str+"=0;"); } GetObj('img_roll1',random_str).scrollLeft+=num; setTimeout('CompScr_1("'+random_str+'")',TempSpeed); } }//武鸣人网站https://www.wuming.ren 网站很好记住,wuming.ren(武鸣拼音.ren域名后缀) function picrun_ini(random_str){ GetObj('img_list2',random_str).innerHTML=GetObj('img_list1',random_str).innerHTML; GetObj('img_roll1',random_str).scrollLeft=fill_1>=0?fill_1:GetObj('img_list1',random_str).scrollWidth-Math.abs(fill_1); GetObj('img_roll1',random_str).onmouseover=function(){eval("clearInterval(AutoPlayObj_"+random_str+");");}; GetObj('img_roll1',random_str).onmouseout=function(){AutoPlay_1(random_str);}; AutoPlay_1(random_str); } //图片自动轮换 var $$ = function (id) { return "string" == typeof id ? document.getElementById(id) : id; }; //武鸣人网站https://www.wuming.ren 网站很好记住,wuming.ren(武鸣拼音.ren域名后缀) var Extend = function(destination, source) { for (var property in source) { destination[property] = source[property]; } return destination; } var CurrentStyle = function(element){ return element.currentStyle || document.defaultView.getComputedStyle(element, null); } //武鸣人网站https://www.wuming.ren 网站很好记住,wuming.ren(武鸣拼音.ren域名后缀) var Bind = function(object, fun) { var args = Array.prototype.slice.call(arguments).slice(2); return function() { return fun.apply(object, args.concat(Array.prototype.slice.call(arguments))); } } //武鸣人网站https://www.wuming.ren 网站很好记住,wuming.ren(武鸣拼音.ren域名后缀) var forEach = function(array, callback, thisObject){ if(array.forEach){ array.forEach(callback, thisObject); }else{ for (var i = 0, len = array.length; i < len; i++) { callback.call(thisObject, array[i], i, array); } } } //武鸣人网站https://www.wuming.ren 网站很好记住,wuming.ren(武鸣拼音.ren域名后缀) var Tween = { Quart: { easeOut: function(t,b,c,d){ return -c * ((t=t/d-1)*t*t*t - 1) + b; } }, Back: { easeOut: function(t,b,c,d,s){ if (s == undefined) s = 1.70158; return c*((t=t/d-1)*t*((s+1)*t + s) + 1) + b; } }, Bounce: { easeOut: function(t,b,c,d){ if ((t/=d) < (1/2.75)) { return c*(7.5625*t*t) + b; } else if (t < (2/2.75)) { return c*(7.5625*(t-=(1.5/2.75))*t + .75) + b; } else if (t < (2.5/2.75)) { return c*(7.5625*(t-=(2.25/2.75))*t + .9375) + b; } else { return c*(7.5625*(t-=(2.625/2.75))*t + .984375) + b; } } } }//武鸣人网站https://www.wuming.ren 网站很好记住,wuming.ren(武鸣拼音.ren域名后缀) //容器对象,滑动对象,切换数量 var SlideTrans = function(container, slider, count, options) { this._slider = $$(slider); this._container = $$(container);//容器对象 this._timer = null;//定时器 this._count = Math.abs(count);//切换数量 this._target = 0;//目标值 this._t = this._b = this._c = 0;//tween参数 this.Index = 0;//当前索引 this.SetOptions(options); this.Auto = !!this.options.Auto; this.Duration = Math.abs(this.options.Duration); this.Time = Math.abs(this.options.Time); this.Pause = Math.abs(this.options.Pause); this.Tween = this.options.Tween; this.onStart = this.options.onStart; this.onFinish = this.options.onFinish; //武鸣人网站https://www.wuming.ren 网站很好记住,wuming.ren(武鸣拼音.ren域名后缀) var bVertical = !!this.options.Vertical; this._css = bVertical ? "top" : "left";//方向 //样式设置 var p = CurrentStyle(this._container).position; p == "relative" || p == "absolute" || (this._container.style.position = "relative"); this._container.style.overflow = "hidden"; this._slider.style.position = "absolute"; this.Change = this.options.Change ? this.options.Change : this._slider[bVertical ? "offsetHeight" : "offsetWidth"] / this._count; };//武鸣人网站https://www.wuming.ren 网站很好记住,wuming.ren(武鸣拼音.ren域名后缀) SlideTrans.prototype = { //设置默认属性 SetOptions: function(options) { this.options = {//默认值 Vertical:true,//是否垂直方向(方向不能改) Auto:true,//是否自动 Change:0,//改变量 Duration:30,//滑动持续时间 Time:10,//滑动延时 Pause:3000,//停顿时间(Auto为true时有效) onStart:function(){},//开始转换时执行 onFinish:function(){},//完成转换时执行 Tween:Tween.Quart.easeOut//tween算子 }; Extend(this.options, options || {}); }, //开始切换 Run: function(index) { //修正index index == undefined && (index = this.Index); index < 0 && (index = this._count - 1) || index >= this._count && (index = 0); //设置参数 this._target = -Math.abs(this.Change) * (this.Index = index); this._t = 0; this._b = parseInt(CurrentStyle(this._slider)[this.options.Vertical ? "top" : "left"]); this._c = this._target - this._b; this.onStart(); this.Move(); }, //移动 Move: function() { clearTimeout(this._timer); //未到达目标继续移动否则进行下一次滑动 if (this._c && this._t < this.Duration) { this.MoveTo(Math.round(this.Tween(this._t++, this._b, this._c, this.Duration))); this._timer = setTimeout(Bind(this, this.Move), this.Time); }else{ this.MoveTo(this._target); this.Auto && (this._timer = setTimeout(Bind(this, this.Next), this.Pause)); } }, //移动到 MoveTo: function(i) { this._slider.style[this._css] = i + "px"; }, //下一个 Next: function() { this.Run(++this.Index); }, //上一个 Previous: function() { this.Run(--this.Index); }, //停止 Stop: function() { clearTimeout(this._timer); this.MoveTo(this._target); } };//武鸣人网站https://www.wuming.ren 网站很好记住,wuming.ren(武鸣拼音.ren域名后缀) function AddNum(i,random_str){ eval('var num_'+random_str+' = $$("idNum_"+random_str).appendChild(document.createElement("li"));'); eval('num_'+random_str+'.innerHTML = i--;'); eval('num_'+random_str+'.onmouseover = function(){timer = setTimeout(function(){ num_'+random_str+'.className = "on"; st_'+random_str+'.Auto = false; st_'+random_str+'.Run(i); }, 200);};'); eval('num_'+random_str+'.onmouseout = function(){ clearTimeout(timer); num_'+random_str+'.className = ""; st_'+random_str+'.Auto = true; st_'+random_str+'.Run(); };'); eval('nums_'+random_str+'[i] = num_'+random_str+';'); }//武鸣人网站https://www.wuming.ren 网站很好记住,wuming.ren(武鸣拼音.ren域名后缀) function gen_content(random_str,data,id){ var str=''; switch (id){ case 'main_1': str='<div id="img_roll_ctn_'+random_str+'" class="img_roll_ctn1">'; str+='<div id="img_switch_btn_prev_'+random_str+'" class="img_switch_btn prev"><A onmouseup="ISL_StopUp_1(\''+random_str+'\')" class=LeftBotton onmousedown="ISL_GoUp_1(\''+random_str+'\')" onmouseout="ISL_StopUp_1(\''+random_str+'\')" href="javascript:void(0);" target=_self><img src="images/spacer.gif" /></A></div>' str+='<div id="img_roll1_'+random_str+'" class="img_roll1">'; str+='<div class="virtual_ctn">'; str+='<div id="img_list1_'+random_str+'" class="img_list2">'; $.each(data,function(entryIndex,entry){ str+='<a href="'+entry.url+'"><img src="'+entry.img+'" alt="'+entry.title+'" title="'+entry.title+'" height="88" width="118"></a>'; }); str+='</div>'; str+='<div id="img_list2_'+random_str+'" class="img_list2"></div>'; str+='</div></div>'; str+='<div id="img_switch_btn_next_'+random_str+'" class="img_switch_btn next"><A onmouseup="ISL_StopDown_1(\''+random_str+'\')" class=RightBotton onmousedown="ISL_GoDown_1(\''+random_str+'\')" onmouseout="ISL_StopDown_1(\''+random_str+'\')" href="javascript:void(0);" target=_self><img src="images/spacer.gif" /></A></div>'; str+='</div>'; break; case 'text_1': str="<div class=\"text_ctn_1\">"; $.each(data,function(entryIndex,entry){ str+='<a href="'+entry.url+'" target="_blank" title="'+entry.title+'">'+entry.title+'</a>'; }); str+="</div>"; break; case 'img_1'://图片自动切换 str='<div class="slider_ctn1" id="slider_container_'+random_str+'">' +'<table id="slider_'+random_str+'" border="0" cellpadding="0" cellspacing="0">' +'<tr>'; $.each(data,function(entryIndex,entry){ str+='<td><a href="'+entry.url+'"><img src="'+entry.img+'" alt="'+entry.title+'" title="'+entry.title+'" /></a></td>' }); str+='</tr>' +'</table>' +'</div>'; break; case 'img_3'://图片自动切换 str='<div class="slider_ctn3" id="slider_container_'+random_str+'">' +'<table id="slider_'+random_str+'" border="0" cellpadding="0" cellspacing="0">' +'<tr>'; var ad_count=0; $.each(data,function(entryIndex,entry){ ad_count++; str+='<td><a href="'+entry.url+'" target="_blank"><img onmouseover = "javascript:st_'+random_str+'.Stop();" onmouseout = "st_'+random_str+'.Run();" src="'+entry.img+'" alt="'+entry.title+'" title="'+entry.title+'" /></a></td>' }); //武鸣人网站https://www.wuming.ren 网站很好记住,wuming.ren(武鸣拼音.ren域名后缀) //eval('num_'+random_str+'.onmouseover = function(){timer = setTimeout(function(){ num_'+random_str+'.className = "on"; st_'+random_str+'.Auto = false; st_'+random_str+'.Run(i); }, 200);};'); //eval('num_'+random_str+'.onmouseout = function(){ clearTimeout(timer); num_'+random_str+'.className = ""; st_'+random_str+'.Auto = true; st_'+random_str+'.Run(); };'); str+='</tr>' +'</table>' +'<ul class="wuming_ren" id="idNum_'+random_str+'">' +'</ul>' +'</div>'; break; case 'img_2'://图片自动切换 str='<div class="slider_ctn2" id="slider_container_'+random_str+'">' +'<ul id="slider_'+random_str+'">'; $.each(data,function(entryIndex,entry){ str+='<li><a href="'+entry.url+'"><img src="'+entry.img+'" alt="'+entry.title+'" title="'+entry.title+'" /> </a></li>'; }); str+='</ul>' +'<ul class="slider_num" id="idNum_'+random_str+'">' +'</ul>' +'</div>'; break; case 'hot_1': var img_str=null,left_str='',text_str=''; $.each(data,function(entryIndex,entry){ if (img_str==null&&typeof entry.img_type=='string'&&entry.img_type=='top'){ img_str='<a href="'+entry.url+'" class="img"><img id="'+random_str+'" src="'+entry.img+'" alt="'+entry.title+'" title="'+entry.title+'" /></a>'; img_str+='<a href="'+entry.url+'" class="text" alt="'+entry.title+'" title="'+entry.title+'">'+entry.title+'</a>'; } else if(img_str==null&&typeof entry.img_type=='string'&&entry.img_type=='left'){ left_str+='<a href="'+entry.url+'" class="text" alt="'+entry.title+'" title="'+entry.title+'">'+entry.title+'</a>'; } else { text_str+='<a class="text" href="'+entry.url+'" alt="'+entry.title+'" title="'+entry.title+'">'+entry.title+'</a>'; } }); str='<div class="hot_show" id="hot_show_ctn_'+random_str+'">' +'<div class="left_ctn">' +img_str+left_str +'</div>' +'<div class="right_ctn">' +text_str +'</div>' +'</div>'; break; case 'fade_1': var str='<ul class="fade_img_ctn" id="fade_img_ctn_'+random_str+'">'; $.each(data,function(entryIndex,entry){ str+='<li><a href="'+entry.url+'"><img src="'+entry.img+'" alt="'+entry.title+'" title="'+entry.title+'" /></a></li>'; }); str+='</ul>'; break; } document.write(str); //图片滚动列表 }//武鸣人网站https://www.wuming.ren 网站很好记住,wuming.ren(武鸣拼音.ren域名后缀) function export_ad(gt_ad){ var random_str=random_char(5); var data; if (typeof gt_ad.data_type!='undefined'&&typeof gt_ad.data!='undefined'&>_ad.data_type=='array') data=gt_ad.data; else data=get_data(gt_ad.service_url,gt_ad.service_para); switch (gt_ad.type_id) { case "main_1": eval("MoveLock_"+random_str+" = false;"); eval("MoveTimeObj_"+random_str+"=null;"); eval("MoveWay_"+random_str+"='right';"); eval("var Comp_"+random_str+" = 0;"); eval('AutoPlayObj_'+random_str+'=null;'); gen_content(random_str,data,gt_ad.type_id); picrun_ini(random_str); //产品展示滚动图片结束 break; case "text_1"://480宽 gen_content(random_str,data,gt_ad.type_id); break; case "img_1"://280*200 gen_content(random_str,data,gt_ad.type_id); $("#slider_container_"+random_str).css('width',typeof gt_ad.width!='string'?'280px':gt_ad.width+'px'); $("#slider_container_"+random_str).css('height',typeof gt_ad.height!='string'?'200px':gt_ad.height+'px'); $("#slider_container_"+random_str+" img").css('width',typeof gt_ad.width!='string'?'280px':gt_ad.width+'px'); $("#slider_container_"+random_str+" img").css('height',typeof gt_ad.height!='string'?'200px':gt_ad.height+'px'); new SlideTrans("slider_container_"+random_str,"slider_"+random_str,data.length, { Vertical: false }).Run(); break; case "img_2"://280*200 gen_content(random_str,data,gt_ad.type_id); $("#slider_container_"+random_str).css('width',typeof gt_ad.width!='string'?'280px':gt_ad.width+'px'); $("#slider_container_"+random_str).css('height',typeof gt_ad.height!='string'?'200px':gt_ad.height+'px'); $("#slider_container_"+random_str+" img").css('width',typeof gt_ad.width!='string'?'280px':gt_ad.width+'px'); $("#slider_container_"+random_str+" img").css('height',typeof gt_ad.height!='string'?'200px':gt_ad.height+'px'); eval('nums_'+random_str+' = []'); eval('var timer, n = $$("slider_"+random_str).getElementsByTagName("li").length;'); str='st_'+random_str+' = new SlideTrans("slider_container_"+random_str, "slider_"+random_str, n, {' +'onStart: function(){'//设置按钮样式 +'forEach(nums_'+random_str+', function(o, i){ o.className = st_'+random_str+'.Index == i ? "on" : ""; });' +'}' +'});'; eval(str); for(var i = 1; i <= n; AddNum(i++,random_str)){}; eval('st_'+random_str+'.Run();'); break; case "img_3"://280*200 gen_content(random_str,data,gt_ad.type_id); $("#slider_container_"+random_str).css('width',typeof gt_ad.width!='string'?'280px':gt_ad.width+'px'); $("#slider_container_"+random_str).css('height',typeof gt_ad.height!='string'?'200px':gt_ad.height+'px'); $("#slider_container_"+random_str+" img").css('width',typeof gt_ad.width!='string'?'280px':gt_ad.width+'px'); $("#slider_container_"+random_str+" img").css('height',typeof gt_ad.height!='string'?'200px':gt_ad.height+'px'); eval('nums_'+random_str+' = []'); eval('var timer, n = data.length;'); str='st_'+random_str+' = new SlideTrans("slider_container_"+random_str, "slider_"+random_str, n, {' +'onStart: function(){'//设置按钮样式 +'forEach(nums_'+random_str+', function(o, i){ o.className = st_'+random_str+'.Index == i ? "on" : ""; });' +'},Vertical: false' +'});'; eval(str); for(var i = 1; i <= n; AddNum(i++,random_str)){}; eval('st_'+random_str+'.Run();'); break; case 'hot_1': gen_content(random_str,data,gt_ad.type_id); $('#hot_show_ctn_'+random_str+' .left_ctn .img img').load(function(){ $('#hot_show_ctn_'+random_str).css('width',gt_ad.width+'px').css('height',gt_ad.height+'px'); $('#hot_show_ctn_'+random_str+' .left_ctn').css('width',(gt_ad.width/2-10)+'px').css('height',(gt_ad.height-10)+'px').css('padding','5px'); var img_total_width=parseInt($('#hot_show_ctn_'+random_str+' .left_ctn .img img').width())+parseInt($('#hot_show_ctn_'+random_str+' .left_ctn .img img').css('padding-left'))+parseInt($('#hot_show_ctn_'+random_str+' .left_ctn .img img').css('padding-right'))+parseInt($('#hot_show_ctn_'+random_str+' .left_ctn .img img').css('border-right-width'))+parseInt($('#hot_show_ctn_'+random_str+' .left_ctn .img img').css('border-left-width')); $('#hot_show_ctn_'+random_str+' .left_ctn .img').css('margin','5px '+(gt_ad.width/2-10-img_total_width)/2+'px 5px'); $('#hot_show_ctn_'+random_str+' .right_ctn').css('width',(gt_ad.width/2-10)+'px').css('height',(gt_ad.height-10)+'px').css('padding','5px'); }); break; case 'fade_1': gen_content(random_str,data,gt_ad.type_id); $('#fade_img_ctn_'+random_str).css('width',gt_ad.width+'px').css('height',gt_ad.height+'px'); $('#fade_img_ctn_'+random_str+' li').css('width',gt_ad.width+'px').css('height',gt_ad.height+'px'); $('#fade_img_ctn_'+random_str+' li img').css('width',gt_ad.width+'px').css('height',gt_ad.height+'px'); break; } }//武鸣人网站https://www.wuming.ren 网站很好记住,wuming.ren(武鸣拼音.ren域名后缀) </script> </head> <body> <a href="https://www.wuming.ren">武鸣人</a>,各种信息资源免费发布,分享励志语录经典短句,减肥健身常识,各种js特效代码。网站很好记住,wuming.ren(武鸣拼音.ren域名后缀)<hr> <!--欢迎来到武鸣人信息资源平台,各种信息免费发布,资源共享合作共赢,分享互联网流行的励志语录经典短句,减肥健身健康小常识及打卡记录,收集各种js特效代码。--> <script type="text/javascript" src="https://www.wuming.ren/ad/tc.js"></script> <script type="text/javascript" src="https://www.wuming.ren/ad/a.js"></script> 需要加载js文件,请刷新页面后看效果! <div id="wwwwumingren"> <div id="wuming"> <script type="text/javascript"> var ad_data=[{"title":"武鸣人一号图片","url":"https://www.wuming.ren/","img":"\/img\/20240419_www_wuming_ren_6.jpg"},{"title":"武鸣人二号图片","url":"https://www.wuming.ren","img":"\/img\/20240419_www_wuming_ren_7.jpg"},{"title":"武鸣人三号图片","url":"https://www.wuming.ren","img":"\/img\/20240419_www_wuming_ren_8.jpg"},{"title":"武鸣人四号图片","url":"https://www.wuming.ren","img":"\/img\/20240419_www_wuming_ren_9.jpg"},{"title":"武鸣人五号图片","url":"https://www.wuming.ren/","img":"\/img\/20240419_www_wuming_ren_10.jpg"}]; var gt_ad={width:"576",height:'260',data_type:'array',data:ad_data,type_id:'img_3'}; export_ad(gt_ad); </script> </div> </div> </body> </html>
本文来自武鸣人网站,转载请注明出处