if(typeof(A4page) == 'undefined') A4page = {}; A4page.Zone = []; A4page.Zone["B1"]={"zonecode":"B1",content:[{ "aid":"16612", "zid":"395", "title":"A8韦博用户注册小问卷", "link":"http://a8.yeshj.com/zt/webi2/", "advtype":"P", "source":"http://a4.yeshj.com/upload/200809/TS-Z-B1P-16612_71.gif", "adFormCode":"B1", "protected":false }]};A4page.Zone["H1"]={"zonecode":"H1",content:[{ "aid":"19057", "zid":"471", "title":"索尼2008全国BEC奖学金开始申请中", "link":"http://www.hjenglish.com/subject/bec/page/57323/", "advtype":"T", "source":"", "adFormCode":"H1", "protected":false }]};A4page.Zone["Z1"]={"zonecode":"Z1",content:[{ "aid":"19409", "zid":"470", "title":"免费提供独家英语学习资料", "link":"http://www.chanet.com.cn/click.cgi?a=96016&d=56455&u=&e=&url=http://cnap.englishtown.com/Sp/Landing/default.aspx?ctr=cn&lng=cs&kwid=95403&cfid=95655&v=2&etag=A03010[DRAFTNAME]FE4", "advtype":"T", "source":"", "adFormCode":"Z1", "protected":false },{ "aid":"18008", "zid":"470", "title":"快来,免费领取儿童英语学习资料喽", "link":"http://a8.yeshj.com/zt/efkids/", "advtype":"T", "source":"", "adFormCode":"Z1", "protected":false },{ "aid":"18007", "zid":"470", "title":"惊:30天,开口说流利的英语!", "link":"http://www.hjbook.net/product/2738", "advtype":"T", "source":"", "adFormCode":"Z1", "protected":false }]}; function show_a4_zone(zonecode) { if(A4page.Zone[zonecode].content[0].advtype == "T"){ for (var i=0, post; post = A4page.Zone[zonecode].content[i]; i++) { if(zonecode.substring(0,1) == "H") document.write("" + post.title +"  "); else document.write("" + post.title +"
"); } } else if (A4page.Zone[zonecode].content[0].advtype == "P"){ if( A4page.Zone[zonecode].content.length == 1 ){ document.write(""); }else{ for (var i=0, post; post = A4page.Zone[zonecode].content[i]; i++) { document.write("

"); } } }else if (A4page.Zone[zonecode].content[0].advtype == "F"){ document.write(ConvertUbb(A4page.Zone[zonecode].content[0].source)); } } function ConvertUbb(Source){ //定义ubb转换参数 var flash_ubb = /\[flash=(\d*),(\d*)\](\S*)\[\/flash\]/igm; var flash_html= "" + "" + "" + "" + ""; //执行转换 Source=Source.replace(flash_ubb, flash_html ); return Source; }