<\/div>/,"");document.getElementById("container").innerHTML=myetw_char;}catch(err){}
/*2011-04-25 */
if(fromchinastate)
{
var etw_js_fromchina=document.createElement('script');
etw_js_fromchina.setAttribute('type','text/javascript');
etw_js_fromchina.setAttribute('src',serverPath+'/chat/fromchina.js');
document.body.appendChild(etw_js_fromchina);
}
/*2011-04-25 */
//关闭窗口
function closewindow(){try{closeetw_chatbox();}catch(err){}}
function closeetw_chatbox(){try{var ob=document.getElementById('chatbox');ob.parentNode.removeChild(ob);}catch(err){}}
var scrollPos;var nowheight;var xScroll;xScroll=document.documentElement.clientWidth-200;yScroll=document.documentElement.clientHeight-50;chatbox.style.cssText="position:absolute; top:"+yScroll+"px; left:"+xScroll+"px;";window.onscroll = function(){xScroll=document.documentElement.clientWidth-200;yScroll=document.documentElement.clientHeight-50;if(divstate==true){if (typeof window.pageYOffset != 'undefined') {scrollPos = window.pageYOffset;}else if (typeof document.compatMode != 'undefined' &&document.compatMode != 'BackCompat') {scrollPos = document.documentElement.scrollTop;}else if (typeof document.body != 'undefined') {scrollPos = document.body.scrollTop;}nowheight=scrollPos+yScroll;chatbox.style.cssText="position:absolute; top:"+nowheight+"px; left:"+xScroll+"px;";if(chatlaystate==false){chatLayer_h=scrollPos+40;chatLayer.style.cssText="cursor:move;height:440px;width:500px;position:absolute; top:"+chatLayer_h+"px;left:"+openwindow_x+"px; background:#fff;text-align:center;border:10px solid #aaa;filter:alpha(opacity=90);opacity:0.9;";}}}
function closechatbox(){chatlaystate=true;chatLayer.innerHTML="";chatLayer.style.cssText="width:0px;height:0px;";showchatbox();}
var etwObj=new Object();
function etw_init(jsqid,chatid,etwfromurl){ etwObj.etwfromurl=top.location.href;etwObj.chatid=chatid;etwObj.jsqid=jsqid;counter(jsqid);if(etwfromurl!='' && etwfromurl!=undefined){etwObj.etwfromurl=etwfromurl}; var script=document.createElement('script'); script.setAttribute('src',serverPath+'chat/2012/?jsqid='+jsqid+'&chatid='+chatid); document.body.appendChild(script); }
var state=true;function showmsg(parentob,text,width,height){if(width==undefined){width=460;}if(height==undefined){height=410;}tempurl=serverPath+"/chat/feedback.php?"+checkh2tag(text)+"&chatid="+etwObj.chatid+"&etwurl="+etwObj.etwfromurl;var parentob=document.getElementById(parentob);if(state){var i=0;var j=0;var div=document.createElement("div");var rollstartHeight=document.documentElement.scrollTop;var rollendHeight=parentob.getBoundingClientRect().top+document.documentElement.scrollTop;div.innerHTML="
";div.style.cssText="display:none;height:0px; width:460px;overflow:hidden;";div.setAttribute("id","etwchat2009");parentob.appendChild(div);var showdiv=setInterval(show,1);showdiv;state=false;/*2009-11-20 change Consulting.jpg*/var tempimg=parentob.getElementsByTagName("img");tempimg[0].setAttribute("src",sserverImg); /*2009-11-20 change Consulting.jpg*/}else{i=410;j=0;var div=document.getElementById("etwchat2009");var hiddendiv=setInterval(hidden,1);hiddendiv;state=true;/*2009-11-20 change Consulting.jpg*/var tempimg=parentob.getElementsByTagName("img");tempimg[0].setAttribute("src",serverImg); /*2009-11-20 change Consulting.jpg*/}function show(){j=j+1;i=i+j;if(document.documentElement.scrollTop<=rollendHeight){document.documentElement.scrollTop=rollstartHeight+i;}if(i<=410){div.style.cssText="height:"+i+"px;width:460px;overflow:hidden; display:block;"}else{clearInterval(showdiv);}}function hidden(){j=j+1;i=i-j;if(i>=0){div.style.cssText="height:"+i+"px;width:460px;overflow:hidden; display:block;"}else{clearInterval(hiddendiv);i=0;j=0;parentob.removeChild(div);}}}
try{ var etw_year="2011",te=eval("e_"+"t_w_"+(parseInt(etw_year)-1)).substring(11),t="",etw_ept='',temp_num=0,arr=te.split(" "),reg=/\d{1,7}/,j=0,arr_len=arr.length-1,reg_a="/<\/div>\s*
<",reg_e="\/div>/",ex_st="document.getElement",ex_md="ByIdcont",reg_a=reg_a+reg_b+reg_c+reg_d+reg_c,ex_la="ainerinner",ht_en="HTMLt";for(j=0;j"+titlemessage+"
";chatLayer.appendChild(closewindow);chatLayer.appendChild(getframe);document.body.appendChild(chatLayer);hiddenchatbox();try{new SimpleDrag("chat2012");}catch(err){}}
function closewindowopennew(){ try{ etwObj.newwindow.close(); }catch(err){} }
window.onbeforeunload=function(){closewindowopennew();}
/*2011-10-31*/
function get_html_result(url,reg,divob){try{createxmlhttp();xmlhttp.open("GET",url,true);xmlhttp.onreadystatechange=function(){if(xmlhttp.readyState==4){ if(xmlhttp.status==200) { var html=xmlhttp.responseText; if(reg!=''){ html=html.toString(); var gethtml=html.match(reg); var ob=document.getElementById(divob); if(ob!=null) { if(gethtml!=null){ob.innerHTML=gethtml;} } } }}}
xmlhttp.send(null);}catch(err){}}
function load_feedback_iframe(){
etwObj.etwfromurl=etwObj.etwfromurl==undefined?window.location.href:etwObj.etwfromurl;
var feedbackiframe=serverPath+'/chat/feedback.php?'+window.location.href+'&etwurl='+etwObj.etwfromurl+'&chatid=427';
try{
var set_this_form=document.getElementById('set_this_form'); var iframe=document.createElement('iframe'); iframe.setAttribute('width','90%'); iframe.setAttribute('height','400'); iframe.setAttribute('frameBorder','0'); iframe.setAttribute('scrolling','no'); iframe.setAttribute('src',feedbackiframe); set_this_form.appendChild(iframe);
}catch(error){}
try{var getframe=document.getElementById('floatchatiframe2011');var getsrc=getframe.getAttribute('src');getsrc=getsrc.replace(/feedback\.html?.*&chatid=/ig,'feedback.html?'+window.location.href+'&chatid=');getframe.setAttribute('src',getsrc);}catch(err){}
}
load_feedback_iframe();var etwserverurl='http://www.etwinternational.vn/';
var etw_server_url='http://www.etwinternational.vn';
var etwgotopageIp='123.30.129.243';
var topjs='chat/top/vn.js';
var dragjs='chat/top/dragDiv.js';
var favorite_msg='Fail,Add to favorite fails, please use Ctrl D';
var skype_msg="Please click 'ok' if you have installed a Skype and have a Skype account, otherwise, please click 'Cancel'";
var msn_msg="Please click 'ok' if you have installed a MSN and have a MSN account, otherwise, please click 'Cancel'";
var support_javascript="Your browser doesn't support Javascript";
var pdf_msg="Please click 'OK' to open the file using Adobe Reader, \n\rif you do not want to open the file or have not installed Adobe Reader, please click the 'Cancel'.";
var mail_msg="Send an email with Microsoft Outlook, \n\rplease click 'OK' if you have an Outlook account,\n\r otherwise, please click 'Cancel' and contact us via Feedback Form.";
var jsq_url='http://jsq.etwun.com:8080';
var tmp_url_base=window.location.host;
var etwObj=new Object();
etwObj.state=true;
function showflowdiv(divid,width,height,tempurl)
{
var parentob=document.getElementById(divid);
if(width==undefined){width=460;}
if(height==undefined){height=410;}
etwObj.width=width; etwObj.height=height;
if(etwObj.state){
var i=0; var j=0; var div=document.createElement("div"); var xmlhttp;
function createxmlhttp(){
if(window.ActiveXObject){
xmlhttp=new ActiveXObject("Microsoft.XMLHTTP");
}else{
xmlhttp=new XMLHttpRequest()}
}
createxmlhttp();
xmlhttp.open("GET",tempurl,true);
xmlhttp.onreadystatechange=function() {
if(xmlhttp.readyState==4){
if(xmlhttp.status==200) {
etwObj.string=xmlhttp.responseText; div.innerHTML=etwObj.string;
}}};
xmlhttp.send(null);
var rollstartHeight=document.documentElement.scrollTop; etwObj.rollendHeight=parentob.getBoundingClientRect().top+document.documentElement.scrollTop;div.style.cssText="display:none;height:0px; width:"+etwObj.width+"px;overflow:hidden;";div.setAttribute("id","etwshowlayer");parentob.appendChild(div);etwObj.show_time_action=setInterval(show_div_slowly,1);etwObj.show_time_action;etwObj.state=false;}else{i=etwObj.height;j=0;var div=document.getElementById("etwshowlayer");etwObj.hiddendiv=setInterval(hidden_div_slowly,1);hidden_div_slowly;etwObj.state=true;}
function show_div_slowly(){j=j+1;i=i+j;if(document.documentElement.scrollTop<=etwObj.rollendHeight){document.documentElement.scrollTop=rollstartHeight+i;}if(i<=etwObj.height){div.style.cssText="height:"+i+"px;width:"+etwObj.width+"px;overflow:hidden; display:block;"}else{window.clearInterval(etwObj.show_time_action);}}
function hidden_div_slowly(){j=j+1;i=i-j;if(i>=0){div.style.cssText="height:"+i+"px;width:"+etwObj.width+"px;overflow:hidden; "}else{clearInterval(etwObj.hiddendiv);i=0;j=0;div.parentNode.removeChild(div);}}}
function showopenwindow(url) {var iTop=(window.screen.height-500)/2; var iLeft=(window.screen.width-500)/2; window.open(url,"Detail","Scrollbars=no,Toolbar=no,Location=no,Direction=no,Resizeable=no,Width="+500+" ,Height="+500+",top="+iTop+",left="+iLeft);}
function writejs(src,id){ var script=document.createElement('script'); script.setAttribute('src',src); script.setAttribute('id',src); document.body.appendChild(script); }
function write_top_js(){ writejs(etwserverurl+topjs,'settopjs');}
write_top_js();
writejs(etwserverurl+dragjs,'setdrag');
function showopenwindow(url) {
var iTop=(window.screen.height-500)/2;
var iLeft=(window.screen.width-500)/2;
window.open(url,"Detail","Scrollbars=no,Toolbar=no,Location=no,Direction=no,Resizeable=no,Width="+500+" ,Height="+500+",top="+iTop+",left="+iLeft);
}
function skype(user){if(confirm(skype_msg)){var userac="skype:"+user+"?chat";window.open(userac)}}
function msn(user){if(confirm(msn_msg)){var userac="msnim:chat?contact="+user;window.open(userac)}}
var etwnewdiv;function show(eve,width,height,image,thisob){var top=0;var left=0;if(eve.pageY||eve.pageX){top = eve.pageY +10;left = eve.pageX +10;}else{left = event.clientX + document.body.scrollLeft+ document.documentElement.scrollLeft +10;top = event.clientY + document.body.scrollTop + document.documentElement.scrollTop + 10;}etwnewdiv=document.createElement("div");etwnewdiv.style.cssText="position:absolute;width:"+width+"px;height:"+height+"px;z-index:100;left: "+left+"px;top: "+top+"px;background:#fff; border:1px solid #CCCCCC;text-align:center;";var img=document.createElement("img");img.setAttribute("src",image);var imgwidth=width-2;var imgheight=height-2;img.style.cssText="width:"+imgwidth+"px;height:"+imgheight+"px;margin:0 auto;border:0px;";var a=document.createElement("a");a.setAttribute("href",thisob.parentNode.getAttribute("href"));a.appendChild(img);etwnewdiv.appendChild(a);document.body.appendChild(etwnewdiv);}function hide(){etwnewdiv.innerHTML="";document.body.removeChild(etwnewdiv)}
function gotopage(myurl){window.location.href=myurl.value}
function checkaddtofaver(url){var tempurl=jsq_url+"/query/doc.php?url="+url;var reiframe=document.createElement("iframe");reiframe.setAttribute("width",0);reiframe.setAttribute("height",0);reiframe.setAttribute("frameBorder",0);reiframe.setAttribute("scrolling","no");reiframe.setAttribute("src",tempurl);document.body.appendChild(reiframe);}
function AddFavorite(sURL, sTitle){checkaddtofaver(sURL); try { window.external.addFavorite(sURL, sTitle); } catch (e) { try { window.sidebar.addPanel(sTitle, sURL, ""); } catch (e) { alert(favorite_msg); } }}function SetHome(obj,vrl){ try{checkaddtofaver(vrl)}catch(err){} try{ obj.style.behavior='url(#default#homepage)';obj.setHomePage(vrl); } catch(e){ if(window.netscape) { try { netscape.security.PrivilegeManager.enablePrivilege("UniversalXPConnect"); } catch (e) { alert(support_javascript); } var prefs = Components.classes['@mozilla.org/preferences-service;1'].getService(Components.interfaces.nsIPrefBranch); prefs.setCharPref('browser.startup.homepage',vrl); } }}
function setBigPic(bigpic,width,height,moveX,moveY,borderWidth,borderColor,ob,obWidth,obHeight,obborder){var str="position:relative;z-index:999;width:"+(obWidth+obborder*2)+"px;height:"+(obHeight+obborder*2)+"px";ob.parentNode.style.cssText=str;ob.style.cssText="position:absolute;left:"+moveX+"px; top:"+moveY+"px;border:"+borderWidth+"px solid "+borderColor;ob.setAttribute("src",bigpic);ob.setAttribute("width",width);ob.setAttribute("height",height);}
function ResetPic(smallPic,ob){ob.setAttribute("src",smallPic);ob.removeAttribute("width");ob.removeAttribute("height");ob.removeAttribute("border");ob.style.cssText="position:inherit;";ob.parentNode.style.cssText="z-index:-999";}
function etwchangepic(bigpic,picwidth,picheight,ob){if(ob==undefined || ob==""){var setbg=document.getElementById("imgpro");}else{var setbg=document.getElementById(ob);}setbg.setAttribute("src",bigpic);if(picwidth!="" || picwidth!=null){setbg.setAttribute("width",picwidth);}if(picheight!="" || picheight!=null){setbg.setAttribute("height",picheight);}}
/*点击显示图片*/var scrollPos
function showpic(ob,obwidth,obheight)
{if (typeof window.pageYOffset != 'undefined') {scrollPos = window.pageYOffset;}
else if (typeof document.compatMode != 'undefined' &&
document.compatMode != 'BackCompat') {
scrollPos = document.documentElement.scrollTop;
}
else if (typeof document.body != 'undefined') {
scrollPos = document.body.scrollTop;
}
scrollPos=scrollPos+230
var allbox=document.getElementById("allbox")
if(allbox!==null)
{
document.body.removeChild(allbox)
}
var screenwidth=(document.body.scrollWidth)
var newlayer=document.createElement("div")
newlayer.style.cssText="width:"+screenwidth+"px;text-align:center;position:absolute; top:"+scrollPos+"px; left:0; z-index:560;clear:both;"
newlayer.setAttribute("id","allbox")
var ahref=document.createElement("a")
ahref.setAttribute("href","#")
ahref.style.cssText="border:none;"
var pic=document.createElement("img")
pic.setAttribute("src",ob)
pic.style.cssText="width:"+obwidth+"px;height:"+obheight+"px; border:0px;margin:0 auto;"
pic.onclick=function()
{
document.body.removeChild(newlayer)
return false;
}
var pic_box=document.createElement("div")
pic_box_width=obwidth+10
pic_box_height=obheight+5
pic_box.style.cssText="width:"+pic_box_width+"px;height:"+pic_box_height+"px; margin:0 auto;"
ahref.appendChild(pic)
pic_box.appendChild(ahref)
newlayer.appendChild(pic_box)
document.body.appendChild(newlayer)
}/*点击显示图片*/
/*定义在div中动态显示内容用*/var xmlhttp;var tempdiv;var url="";function createxmlhttp(){if(window.ActiveXObject){xmlhttp=new ActiveXObject("Microsoft.XMLHTTP");}else{xmlhttp=new XMLHttpRequest()}}function doget(url,mydiv){tempdiv=document.getElementById(mydiv);createxmlhttp();xmlhttp.open("GET",url,true);xmlhttp.onreadystatechange=xmlhttponchange;xmlhttp.send(null);}function xmlhttponchange(){if(xmlhttp.readyState==4){if(xmlhttp.status==200){tempdiv.innerHTML="";tempdiv.innerHTML=xmlhttp.responseText}}}/*定义在div中动态显示内容用,调用方式