有没有 百度图片浏览 功能打代码,类似这个链接一样http://image.baidu.com/i?ct=503316480&z=0&tn=baiduimagedetail&word=%D7%B0%CA%CE&in=7649&cl=2&lm=-1&pn=8&rn=1&di=13294801170&ln=2001&fr=&fmq=&ic=0&s=0&se=1&sme=1&tab=&width=&height=&face=0&is=&istype=2#pn9&-1
谢了

解决方案 »

  1.   


    BD.IMG.albumConf={preCacheMaxNum:1,nextCacheMaxNum:1,displayNum:4,displayPosition:2,nexPageKey:39,prePageKey:37,browsePreKey:38,browseNextKey:40};BD.IMG.detaiImg=(function(){var host="i";try{document.execCommand("BackgroundImageCache",false,true)}catch(e){}window.onerror=function(){return true};function trim(str){return str.replace(/(^[\s\t\xa0\u3000]+)|([\u3000\xa0\s\t]+$)/g,"")}BD.IMG.trim=trim;function json2Query(json){if(json==null||typeof json!="object"){return json}var query=[];for(var i in json){query[query.length]=i+"="+json[i]}return query.join("&")}BD.IMG.json2Query=json2Query;function query2Json(query){if(query==null||typeof query!="string"){return query}var json={};var queryMap=query.split("&");for(var i=0,len=queryMap.length;i<len;i++){var s=queryMap[i].split("=");json[s[0]]=s[1]}return json}BD.IMG.query2Json=query2Json;var searchConf=query2Json(window.location.search.substring(1));function G(id){return document.getElementById(id)}function customSubStr(str,n,addStr){var r=/[^\x00-\xff]/g;if(str.replace(r,"mm").length<=n){return str}var i,m;for(i=0,m=0;i<str.length,m<n;i++){m+=str.charAt(i).replace(r,"mm").length}if(m>n){i--}return str.substring(0,i)+addStr}BD.IMG.customSubStr=customSubStr;var Browser=(function(){var isIE=(navigator.userAgent.indexOf("MSIE")!=-1)&&!window.opera;var isWebKit=(navigator.userAgent.indexOf("AppleWebKit/")>-1);var isOpera=(typeof window.opera!=="undefined")?true:false;var isGecko=(navigator.userAgent.indexOf("Gecko")>-1)&&(navigator.userAgent.indexOf("KHTML")==-1);return{isIE:isIE,isWebKit:isWebKit,isOpera:isOpera,isGecko:isGecko}})();BD.IMG.Browser=Browser;if(!Browser.isIE){function __attachEvent(type,handler){type=type.replace(/^on/,"");this.addEventListener(type,handler,false)}window.attachEvent=document.attachEvent=HTMLElement.prototype.attachEvent=__attachEvent;function __detachEvent(type,handler){type=type.replace(/^on/,"");this.removeEventListener(type,handler,false)}window.detachEvent=document.detachEvent=HTMLElement.prototype.detachEvent=__detachEvent}function addStyle(a,b){var c=document.styleSheets[0];if(c.addRule){c.addRule(a,b)}else{if(c.insertRule){c.insertRule(a+" { "+b+" }",c.cssRules.length)}}}function getBodySize(){var W=0,H=0,SL=0,ST=0,SW=0,SH=0;var w=window,d=document,dd=d.documentElement;W=dd.clientWidth||d.body.clientWidth;H=w.innerHeight||dd.clientHeight||d.body.clientHeight;ST=d.body.scrollTop||dd.scrollTop;SL=d.body.scrollLeft||dd.scrollLeft;SW=Math.max(d.body.scrollWidth,dd.scrollWidth||0);SH=Math.max(d.body.scrollHeight,dd.scrollHeight||0,H);return{w:W,h:H,sw:SW,sh:SH}}function getW(){var W=0;var d=document,dd=d.documentElement;W=dd.clientWidth||d.body.clientWidth;return W}function getMatrix(){var fwidth=0;if(BD.IMG.getCookie("fb")=="1"){fwidth=120}var w=getW()-fwidth;if(w>=0&&w<580){return[3,3]}else{if(w>=580&&w<810){return[3,4]}else{if(w>=810&&w<1034){return[3,5]}else{if(w>=1034&&w<1286){return[3,6]}else{return[3,7]}}}}}BD.IMG.getMatrix=getMatrix;String.prototype.replaceS=function(){if(arguments.length==0){return this}for(var i=0,len=arguments.length,s=this;i<len;i++){s=s.replace(new RegExp("#\\{"+(i+1)+"\\}#","g"),arguments[i])}return s};if(window.HTMLElement){HTMLElement.prototype.__defineGetter__("children",function(){var tmp=[],j=0,n;for(var i=0;i<this.childNodes.length;i++){n=this.childNodes[i];if(n.nodeType==1){tmp[j++]=n;if(n.name){if(!tmp[n.name]){tmp[n.name]=[]}tmp[n.name][tmp[n.name].length]=n}if(n.id){tmp[n.id]=n}}}return tmp})}function zoom(w,h){if((this.srcWidth>w)||(this.srcHeight>h)){var widthRate=w/this.srcWidth;var heightRate=h/this.srcHeight;if(widthRate<heightRate){this.style.width=w+"px";this.style.height=this.srcHeight*widthRate+"px";this.zoomRate=widthRate}else{this.style.width=this.srcWidth*heightRate+"px";this.style.height=h+"px";this.zoomRate=heightRate}}else{this.zoomRate=1;this.style.width=this.srcWidth+"px";this.style.height=this.srcHeight+"px"}}function zoomImg(w,h,max){var widthRate=max/w;var heightRate=max/h;var height=h,width=w;if(widthRate<heightRate){width=max;height=h*widthRate}else{width=w*heightRate;height=max}return{width:width,height:height}}if(!Browser.isOpera){addStyle("#imgList div img","display:none")}function smallImageZoom(obj,max){max=max||100;obj.style.display="inline";obj.srcWidth=obj.width;obj.srcHeight=obj.height;obj.zoom=zoom;obj.zoom(max,max)}BD.IMG.smallImgZoom=smallImageZoom;functio
    这是百度的源码,上面写的清清楚楚,你不会自己看啊