if(typeof(A4page) == 'undefined') A4page = {}; A4page.Zone = [];
A4page.Zone["A1"]={"zonecode":"A1",content:[{ "aid":"34283", "zid":"147", "title":"BEC网校春季班", "link":"http://www.hjenglish.com/subject/bec/page/94789/", "advtype":"P", "source":"http://a4.yeshj.com/upload/201001/TS-Z-A1P-34283_68.gif", "adFormCode":"A1", "protected":false }]};A4page.Zone["B1"]={"zonecode":"B1",content:[{ "aid":"23852", "zid":"146", "title":"BC", "link":"http://brand.hjenglish.com/bc/", "advtype":"P", "source":"http://a4.yeshj.com/upload/200902/TS-Z-B1P-23852_11.gif", "adFormCode":"B1", "protected":false }]};A4page.Zone["B3"]={"zonecode":"B3",content:[{ "aid":"29255", "zid":"830", "title":"新概念网络在线课程", "link":"http://www.hjbook.net/zt/snce", "advtype":"P", "source":"http://a4.yeshj.com/upload/200906/TS-Z-B3P-29255_49.jpg", "adFormCode":"B3", "protected":false }]};A4page.Zone["H1"]={"zonecode":"H1",content:[{ "aid":"27193", "zid":"148", "title":"足不出户,轻松学英语!", "link":"http://class.yeshj.com/zt/en/?source=147", "advtype":"T", "source":"", "adFormCode":"H1", "protected":false },{ "aid":"10288", "zid":"148", "title":"不是达人也能享受音乐", "link":"http://bulo.hjenglish.com/group/100705/", "advtype":"T", "source":"", "adFormCode":"H1", "protected":false },{ "aid":"10287", "zid":"148", "title":"沪江英乐电台火热订阅收听中", "link":"http://bulo.hjenglish.com/podcast/channel/228/", "advtype":"T", "source":"", "adFormCode":"H1", "protected":false },{ "aid":"10286", "zid":"148", "title":"求助: 如何通过听歌提高听力?", "link":"http://www.hjbbs.com/thread-43-465519.htm", "advtype":"T", "source":"", "adFormCode":"H1", "protected":false }]};A4page.Zone["H2"]={"zonecode":"H2",content:[{ "aid":"15159", "zid":"149", "title":"沪江网校,让学习变成一种爱好", "link":"http://class.yeshj.com/zt/en/?source=147", "advtype":"T", "source":"", "adFormCode":"H2", "protected":false },{ "aid":"10291", "zid":"149", "title":"【推荐】卡西欧词典新品上市", "link":"http://www.casio.com.cn/dic/", "advtype":"T", "source":"", "adFormCode":"H2", "protected":false },{ "aid":"10290", "zid":"149", "title":"加入沪江英乐电台小组,签到送红包!", "link":"http://bulo.hjenglish.com/group/topic/45489/", "advtype":"T", "source":"", "adFormCode":"H2", "protected":false }]};
function show_a4_zone(zonecode)
{
if( typeof(A4page.Zone[zonecode]) == "undefined" ) return;
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;
}