
﻿
var IE=document.all?true:false;function Limit_Text(textObj,evt,maxLen){if(textObj.value.length>=maxLen){evt.keyCode=0;}}
function Limit_Text1(textObj,maxLen){if(textObj.value.length>=maxLen){textObj.value=textObj.value.substring(0,maxLen);}}
function OpenRemark(remarkID,buttonID,nrmHeight)
{if(window.document.getElementById(remarkID).style.height=='100%')
{if(nrmHeight==undefined)
nrmHeight='50px';window.document.getElementById(remarkID).style.height=nrmHeight;window.document.getElementById(buttonID).className='down_btn';}
else
{window.document.getElementById(remarkID).style.height='100%';window.document.getElementById(buttonID).className='up_btn';}
return false;}
function showBigImg(bigImg)
{var _bigImg=window.document.getElementById(bigImg);if(_bigImg.complete)
_bigImg.style.display='';else
window.setTimeout("showBigImg('"+bigImg+"');",10);}
function ViewBigImage(bigImg,divID,vis,e,url)
{var _divID=window.document.getElementById(divID);_divID.style.display=vis;if(vis!='none')
{var tempX=0;var tempY=0;var _bigImg=window.document.getElementById(bigImg);_bigImg.style.display=vis;_bigImg.src=url;window.setTimeout("showBigImg('"+bigImg+"');",10);if(IE)
{tempX=e.clientX+document.body.scrollLeft;tempY=e.clientY+document.body.scrollTop;}
else
{tempX=e.pageX+document.body.scrollLeft;;tempY=e.pageY+document.body.scrollTop;}
if(window.document.dir=='rtl')
{tempX=tempX-_divID.offsetWidth;if(e.srcElement)
tempX=tempX-e.srcElement.offsetWidth}
_divID.style.left=tempX+'px';_divID.style.top=tempY+'px';}
return false;}
function ChangeRowBackgroundColor(rowObj,wColor){rowObj.style.backgroundColor=wColor;}
function SetDynamicStyleRule(){var stSh=window.document.styleSheets[0];if(window.document.dir=='ltr')
{if(stSh.addRule)
{stSh.addRule('td.parent_command','border-right-color:silver;border-right-style:solid;border-right-width:1px;width:50%;');stSh.addRule('.padding','padding-right:8px;');}
else if(stSh.insertRule)
{stSh.insertRule('td.parent_command {border-right-color:silver;border-right-style:solid;border-right-width:1px;width:50%;}',0);stSh.insertRule('.padding {padding-right:8px;}',0);}}
else
{if(stSh.addRule)
{stSh.addRule('td.parent_command','border-left-color:silver;border-left-style:solid;border-left-width:1px;width:50%;');stSh.addRule('.padding','padding-left:8px;');}
else if(stSh.insertRule)
{stSh.insertRule('td.parent_command {border-left-color:silver;border-left-style:solid;border-left-width:1px;width:50%;}',0);stSh.insertRule('.padding {padding-left:8px;}',0);}}}
function SetLogoVisibility()
{if(document.body.clientWidth<970)
{if(document.getElementById('imgLogoLeft'))
document.getElementById('imgLogoLeft').style.display='none';if(document.getElementById('imgLogoRight'))
document.getElementById('imgLogoRight').style.display='none';if((window.location.href.indexOf("WP_Product.aspx")>0||window.location.href.indexOf("WP_ProductLite.aspx")>0)&&document.getElementById('TD_MY_GoogleAdSence1')!=null)
{document.getElementById('TD_MY_GoogleAdSence1').style.display='none';document.getElementById('TD_MY_GoogleAdSence1_Caption').style.display='none';}}
else
{if(document.getElementById('imgLogoLeft'))
document.getElementById('imgLogoLeft').style.display='';if(document.getElementById('imgLogoRight'))
document.getElementById('imgLogoRight').style.display='';if((window.location.href.indexOf("WP_Product.aspx")>0||window.location.href.indexOf("WP_ProductLite.aspx")>0)&&document.getElementById('TD_MY_GoogleAdSence1')!=null)
{document.getElementById('TD_MY_GoogleAdSence1').style.display='';document.getElementById('TD_MY_GoogleAdSence1_Caption').style.display='';}}}