document.write(""); function HtmlDecode(text){return text.replace(/&/g,'&').replace(/"/g,'\"').replace(/</g,'<').replace(/>/g,'>')} function XTopMap(w, h, strTopMap){ var m_TopImgs = new Array(); var m_w = w;var m_h = h;var addW = 2; var m_nowPic = 0;var m_hTimer; var m_strTopMap = strTopMap; this.TopImgItem = function (imgUrl, strUrl, strText){this.img = new Image();this.img.src = imgUrl;this.strUrl = strUrl;this.strText = HtmlDecode(strText);} this.AddImgItem = function (strUrl, imgUrl, strText){m_TopImgs[m_TopImgs.length] = new this.TopImgItem(imgUrl, strUrl, strText);} this.Length = function(){return m_TopImgs.length;} this.GetTopImgItem = function(l){return m_TopImgs[l];} this.change_img = function(){ if(!m_nowPic){m_nowPic = 1;} document.getElementById(m_strTopMap + "_pic").src = m_TopImgs[m_nowPic-1].img.src;document.getElementById(m_strTopMap + "_url").href = m_TopImgs[m_nowPic-1].strUrl; document.getElementById(m_strTopMap + "_pic").alt = m_TopImgs[m_nowPic-1].strText; document.getElementById(m_strTopMap + "_title").value = m_TopImgs[m_nowPic-1].strText.replace("'","'"); for (var i=1;i<=m_TopImgs.length;i++){document.getElementById(m_strTopMap + "_xxjdjj"+i).className='';} document.getElementById(m_strTopMap + "_xxjdjj"+m_nowPic).className='here';m_nowPic++; if( m_nowPic > m_TopImgs.length ){m_nowPic = 1} hTimer = setTimeout('eval("'+m_strTopMap+'.change_img()")', 3000); } this.imgClick = function(n){m_nowPic = n;window.clearInterval(hTimer);this.change_img();} this.show = function(){ document.write('
'); document.write('
'); for(var i=1;i'+i+'');} document.write('
'); } } TopMap1 = new XTopMap(255, 228, "TopMap1");var TopMap = TopMap1; TopMap.AddImgItem("http://www.unicef.org/chinese/index.php", "ad/index_ad1.jpg", "联合国儿童基金会"); TopMap.show();TopMap.change_img();