﻿
function doZoom(size)
{document.getElementById('tdContent').style.fontSize=size+'px';}

function doPrint() {
bdhtml=window.document.body.innerHTML;
sprnstr="<!--startprint-->";
eprnstr="<!--endprint-->";
prnhtml=bdhtml.substr(bdhtml.indexOf(sprnstr)+17);
prnhtml=prnhtml.substring(0,prnhtml.indexOf(eprnstr));
window.document.body.innerHTML=prnhtml;
window.print();
document.getElementById('aBack').style.display="block";
}

function doback() {
document.getElementById('aBack').style.display="none";
window.location.reload();
}

function PrintScreen()
{
 var popupScreen = window.open("", "print_win","height=350, width=320, top=0, left=0, toolbar=no, menubar=no, scrollbars=auto,resizable=no,location=no, status=no");  
 popupScreen.document.open();  
  popupScreen.document.write('<LINK href="/App_Themes/default/newStyle.css" type="text/css" rel="styleSheet">');
 popupScreen.document.write('<table width=300 cellpadding=0 cellspacing=0 border=0 ><tr><td class=NewsBigTitle height="25">'); 
 popupScreen.document.write(document.getElementById('tdTitle').innerHTML);
 popupScreen.document.write('</td></tr>');
 
 
 popupScreen.document.write('<tr><td class=NewsDate height="25">'); 
 popupScreen.document.write(document.getElementById('tdDate').innerHTML);
 popupScreen.document.write('</td></tr>');
 
 
 popupScreen.document.write('<tr><td class=NewsContent>'); 
 popupScreen.document.write(document.getElementById('tdContent').innerHTML);
 popupScreen.document.write('</td></tr></table>');
 
 popupScreen.document.close();
 popupScreen.focus();
 popupScreen.print();
}


//include javascript
function IncludeJS( id, fileUrl ) 
{ 
    var scriptTag = document.getElementById( id ); 
    var oHead = document.getElementsByTagName('HEAD').item(0); 
    var oScript= document.createElement("script"); 
    if ( scriptTag  ) oHead.removeChild( scriptTag  );
    oScript.id = id; 
    oScript.type = "text/javascript"; 
    oScript.src=fileUrl ; 
    oHead.appendChild( oScript); 
}

function __crskin_KeyDown(iKeyCode, sFunc, e)
{
	if (e == null)
		e = window.event;

	if (e.keyCode == iKeyCode)
	{
		eval(unescape(sFunc));
		return false;
	}
}

function getImg(obj,scr)
{
 obj.src=scr;
}

function getMenu(key)
{
 document.getElementById("menu_881").style.display="none" ;
 document.getElementById("menu_903").style.display="none" ;
 document.getElementById("menu_904channel").style.display="none" ;
 document.getElementById("menu_news").style.display="none" ;
 document.getElementById("menu_finance").style.display="none" ;
 document.getElementById("menu_shop").style.display="none" ;
 if(key=="1")
  document.getElementById("menu_881").style.display="block" ;
   if(key=="2")
  document.getElementById("menu_903").style.display="block" ;
   if(key=="3")
  document.getElementById("menu_904channel").style.display="block" ;
   if(key=="4")
  document.getElementById("menu_news").style.display="block" ;
   if(key=="5")
  document.getElementById("menu_finance").style.display="block" ;
   if(key=="6")
  document.getElementById("menu_shop").style.display="block" ;
}


function SetFocus(octlid, e)   
  {   
      if   (e.keyCode   ==   13)   
      {
        window.document.getElementById(octlid).focus();
      }
  }
  
function DefautlSetFocus(octlid)   
  {   
     window.document.getElementById(octlid).focus();
  }
 

//Run Flash SWF
IncludeJS("AC_RunActiveContent","/js/AC_RunActiveContent.js");
IncludeJS("mt_js","/js/mt_js.js");
IncludeJS("png_transparent","/js/png_transparent.js");
