if(typeof(A4page) == 'undefined') A4page = {}; A4page.Zone = [];
A4page.Zone["B1"]={"zonecode":"B1",content:[{ "aid":"10166", "zid":"106", "title":"朗阁雅思", "link":"http://www.longre.com/shanghai/09spring.html", "advtype":"P", "source":"http://a4.yeshj.com/upload/200902/EN-O-B1P-10166_57.gif", "adFormCode":"B1", "protected":false }]};A4page.Zone["D9"]={"zonecode":"D9",content:[{ "aid":"34288", "zid":"916", "title":"BEC春季班", "link":"http://www.hjenglish.com/subject/bec/page/94789/", "advtype":"P", "source":"http://a4.yeshj.com/upload/201001/EN-O-D9P-34288_52.jpg", "adFormCode":"D9", "protected":false }]};A4page.Zone["H1"]={"zonecode":"H1",content:[{ "aid":"34289", "zid":"920", "title":"学习商务英语,改变你的职业前景", "link":"http://www.hjenglish.com/subject/bec/page/94789/", "advtype":"T", "source":"", "adFormCode":"H1", "protected":false }]};A4page.Zone["Z1"]={"zonecode":"Z1",content:[{ "aid":"33827", "zid":"918", "title":"商务英语初级水平提高", "link":"http://www.hjenglish.com/subject/bec/page/94789/", "advtype":"T", "source":"", "adFormCode":"Z1", "protected":false },{ "aid":"33826", "zid":"918", "title":"2010年3月英语口译【高口寒假班】", "link":"http://class.yeshj.com/10036/intro", "advtype":"T", "source":"", "adFormCode":"Z1", "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;
}