<!--
function Get_Cookie(name) { 
   var start = document.cookie.indexOf(name+"="); 
   var len = start+name.length+1; 
   if ((!start) && (name != document.cookie.substring(0,name.length))) return null; 
   if (start == -1) return null; 
   var end = document.cookie.indexOf(";",len); 
   if (end == -1) end = document.cookie.length; 
   return unescape(document.cookie.substring(len,end)); 
} 

function warrantTrade() {
	var warrWindow = null;
    var P2G = Get_Cookie('P2G');
    var B2G = Get_Cookie('B2G');

    if ((P2G == null) && (B2G == null)) {
      warrWindow = window.open('', 'EbankLogon','width=520,height=250,status=yes,directories=no,toolbar=no,resizable=no,menubar=no,scrollbars=no,screenX=80,screenY=80');
			warrWindow.location.href='http://www.hangseng.com/einvc/chi/warrant_select_logon.htm';
    } else {
      warrWindow = window.open('', 'EbankControl','width=500,height=370,status=yes,directories=no,toolbar=no,resizable=yes,menubar=no,scrollbars=yes,screenX=80,screenY=80');
	  		warrWindow.location.href='http://www.hangseng.com/logon/chi/pib/logon.aspx?srvc=sts';
    }

    warrWindow.focus();   
}

//-->
