/***********************************************
* AnyLink Vertical Menu- ?Dynamic Drive (www.dynamicdrive.com)
* This notice MUST stay intact for legal use
* Visit http://www.dynamicdrive.com/ for full source code
***********************************************/
//HTTP or HTTPS
var httpvar = 'http://' +  document.domain ;
var httpsvar = 'https://' +  document.domain ;

//Contents for menu "Home"
var menu1=new Array()
menu1[0]='<a href="#">What&#39s News Asia</a>'
menu1[1]='<a href="#">WSJB Latest News</a>'
menu1[2]='<a href="#">FEER Latest News</a>'
menu1[3]='<a href="#">Latest Events</a>'

//Contents for menu "Subscribe"
var menu2=new Array()
//menu2[0]='<a href="' + httpvar + '/general_sub_form">Personal Subscription</a>'
menu2[0]='<table width="100%" border="0" cellspacing="0" cellpadding="0"><tr onClick="clickreturnvalue()" onMouseover="dropdownmenu2(this, event, menu9, ' + "'155px'" + ' )" onMouseout="delayhidemenu2()"><td width="92%"><a href="' + httpvar + '/general_sub_form">Personal Subscription</a></td><td width="8%" style="border-bottom: 1px solid #333333"><img border="0" src="images/arrow3.jpg" width="8" height="12"></td></tr></table>'
//menu2[1]='<a href="' + httpvar + '/subscribe2.html?sub_type=1">Student Subscription</a>'
menu2[1]='<table width="100%" border="0" cellspacing="0" cellpadding="0"><tr onClick="clickreturnvalue()" onMouseover="dropdownmenu2(this, event, menu10, ' + "'155px'" + ' )" onMouseout="delayhidemenu2()"><td width="92%"><a href="/subscribe2.html?sub_type=1">Student Subscription</a></td><td width="8%" style="border-bottom: 1px solid #333333"><img border="0" src="images/arrow3.jpg" width="8" height="12"></td></tr></table>'
menu2[2]='<a href="' + httpvar + '/bulk_subs.html">Bulk Subscription</a>'
//menu2[3]='<a href="' + httpvar + '/subscribe2.html?sub_type=2">Gift Subscription</a>'
menu2[3]='<table width="100%" border="0" cellspacing="0" cellpadding="0"><tr onClick="clickreturnvalue()" onMouseover="dropdownmenu2(this, event, menu11, ' + "'155px'" + ' )" onMouseout="delayhidemenu2()"><td width="92%"><a href="' + httpvar + '/subscribe2.html?sub_type=2">Gift Subscription</a></td><td width="8%" style="border-bottom: 1px solid #333333"><img border="0" src="images/arrow3.jpg" width="8" height="12"></td></tr></table>'

//Contents for menu "Take a tour"
var menu4=new Array()
menu4[0]='<a href="' + httpvar + '/pdf/WSJA_ReaderGuide.pdf" target="blank">WSJA Reader&#8217;s Guide (PDF 4.5MB)</a>'
//menu4[1]='<a href="' + httpvar + '/#digitaltour" onclick="javascript:window.open(\'http://wsja.newsstand.com/tour.cfm\', \'digitaltour\', \'width=640,height=450,toolbar=0,location=0,status=1,menubar=0,scrollBars=0,top=0,left=0\');">Digital Edition Tour</a>'
menu4[1]='<a href="' + httpvar + '/#wsjtour" onclick="javascript:window.open(\'http://online.wsj.com/j2tour/welcome.html\', \'wsjtour\', \'top=18,left=23,toolbar=no,directories=no,status=no,menubar=no,scrollbars=no,resizable=no,width=765 ,height=515\');">asia.WSJ.com Tour</a>'

//Contents for menu "Features"
var menu5=new Array()
menu5[0]='<a href="[!makeURL?id=62!]">WSJA Reports</a>'
menu5[1]='<a href="[!makeURL?id=63!]">Executive Lifestyle Program</a>'
menu5[2]='<a href="[!makeURL?id=64!]">SME Program</a>'
//menu5[3]='<a href="' + httpvar + '/flp.html">Future Leadership Program</a>'
//menu5[4]='<a href="' + httpvar + '/eat.html">EAT! With WSJA</a>'
menu5[5]='<a href="' + httpvar + '/cfm/index.html" target=_blank>CFM Conference</a>'
menu5[6]='<a href="[!makeURL?id=66!]">Bulk Sales Program</a>'

//Contents for menu "Future Leadership Program"
var menu6=new Array()
menu6[0]='<a href="' + httpvar + '/flp/about.html">About FLP</a>'
menu6[1]='<a href="' + httpvar + '/flp/au">Australia</a>'
menu6[2]='<a href="' + httpvar + '/flp/jp">Japan</a>' 
/*
menu6[0]='<a href="' + httpvar + '/flp/about.html">About FLP</a>'
menu6[1]='<a href="' + httpvar + '/flp/china.html">China</a>'
menu6[2]='<a href="' + httpvar + '/flp/hongkong.html">Hong Kong ELI</a>'
menu6[3]='<a href="' + httpvar + '/flp/india.html">India</a>' 
menu6[4]='<a href="' + httpvar + '/flp/japan.html">Japan</a>' 
menu6[5]='<a href="' + httpvar + '/flp/malaysia.html">Malaysia</a>' 
menu6[6]='<a href="' + httpvar + '/flp/taiwan.html">Taiwan</a>'
menu6[7]='<a href="' + httpvar + '/flp/singapore.html">Singapore</a>'
*/

//Contents for menu "Technology and Business Leadership"
var menu13=new Array()
menu13[0]='<a href="' + httpvar + '/tli/india/">India</a>'

//Contents for menu "Manage My Account"
var menu7=new Array()
menu7[0]='<a href="' + httpsvar + '/manage_acct/change_details.html">Change My Account Details</a>'
menu7[1]='<a href="' + httpvar + '/subscribe2.html?sub_type=3">Renew My Subscription</a>'
menu7[2]='<a href="' + httpsvar + '/manage_acct/pay_bill.html">Pay My Bill Online</a>'
menu7[3]='<a href="' + httpsvar + '/manage_acct/forward_add.html">Set Temporary Forwarding Address</a>'
menu7[4]='<a href="' + httpsvar + '/manage_acct/suspend_add.html">Temporarily Suspend Delivery</a>'
menu7[5]='<a href="http://online.wsj.com/onthemove" target="_blank">Register your WSJ.com account</a>'

//Contents for menu "Abount WSJ Asia"
var menu8=new Array()
menu8[0]='<a href="' + httpvar + '/about_wsja.html">About The Journal Asia</a>'
menu8[1]='<a href="' + httpvar + '/contact_us.html">Contact Us</a>'
menu8[2]='<a href="' + httpvar + '/advertise.html">Advertise with Us</a>'

//Contents for submenu for "Personal Subscription"
var menu9=new Array()
menu9[0]='<a href="' + httpsvar + '/general_sub_form?country=australia" >Australia</a>'
menu9[1]='<a href="' + httpsvar + '/general_sub_form?country=brunei">Brunei</a>'
menu9[2]='<a href="' + httpsvar + '/general_sub_form?country=china">China</a>'
menu9[3]='<a href="' + httpsvar + '/general_sub_form?country=hk">Hong Kong</a>'
menu9[4]='<a href="' + httpsvar + '/subhome/subscription_india" >India</a>'
menu9[5]='<a href="' + httpsvar + '/general_sub_form?country=indonesia">Indonesia</a>'
menu9[6]='<a href="' + httpsvar + '/general_sub_form?country=japan">Japan</a>'
menu9[7]='<a href="' + httpsvar + '/general_sub_form?country=korea">Korea</a>'
menu9[8]='<a href="' + httpsvar + '/general_sub_form?country=malaysia" >Malaysia</a>'
menu9[9]='<a href="' + httpsvar + '/general_sub_form?country=macau">Macau</a>'
menu9[10]='<a href="' + httpsvar + '/general_sub_form?country=new_zealand">New Zealand</a>'
menu9[11]='<a href="' + httpsvar + '/general_sub_form?country=pacific_islands">Pacific Islands</a>'
menu9[12]='<a href="' + httpsvar + '/general_sub_form?country=pakistan" >Pakistan</a>'
menu9[13]='<a href="' + httpsvar + '/general_sub_form?country=philippines">Philippines</a>'
menu9[14]='<a href="' + httpsvar + '/general_sub_form?country=singapore">Singapore</a>'
menu9[15]='<a href="' + httpsvar + '/general_sub_form?country=sri_lanka">Sri Lanka</a>'
menu9[16]='<a href="' + httpsvar + '/general_sub_form?country=taiwan">Taiwan</a>'
menu9[17]='<a href="' + httpsvar + '/general_sub_form?country=thailand" >Thailand</a>'
menu9[18]='<a href="' + httpsvar + '/general_sub_form?country=vietnam">Vietnam</a>'
menu9[19]='<a href="' + httpsvar + '/general_sub_form?country=other_asian_countries">Other Asian Countries</a>'
menu9[20]='<a href="' + httpsvar + '/general_sub_form?country=europe">Europe</a>'
menu9[21]='<a href="' + httpsvar + '/general_sub_form?country=north_america" >North America</a>'
menu9[22]='<a href="' + httpsvar + '/general_sub_form?country=rest_of_the_world">Rest of the World</a>'//Contents for submenu for "Student Subscription"
var menu10=new Array()
menu10[0]='<a href="' + httpsvar + '/formfile/student_form.html?country=0&sub_type=1" >Australia</a>'
menu10[1]='<a href="' + httpsvar + '/formfile/student_form.html?country=1&sub_type=1">Brunei</a>'
menu10[2]='<a href="' + httpsvar + '/formfile/student_form.html?country=2&sub_type=1">China</a>'
menu10[3]='<a href="' + httpsvar + '/formfile/student_form.html?country=3&sub_type=1">Hong Kong</a>'
menu10[4]='<a href="' + httpsvar + '/subhome/subscription_india" >India</a>'
menu10[5]='<a href="' + httpsvar + '/formfile/student_form.html?country=5&sub_type=1">Indonesia</a>'
menu10[6]='<a href="' + httpsvar + '/formfile/student_form.html?country=6&sub_type=1">Japan</a>'
menu10[7]='<a href="' + httpsvar + '/formfile/student_form.html?country=7&sub_type=1">Korea</a>'
menu10[8]='<a href="' + httpsvar + '/formfile/student_form.html?country=8&sub_type=1" >Malaysia</a>'
menu10[9]='<a href="' + httpsvar + '/formfile/student_form.html?country=9&sub_type=1">Macau</a>'
menu10[10]='<a href="' + httpsvar + '/formfile/student_form.html?country=10&sub_type=1">New Zealand</a>'
menu10[11]='<a href="' + httpsvar + '/formfile/student_form.html?country=11&sub_type=1">Pacific Islands</a>'
menu10[12]='<a href="' + httpsvar + '/formfile/student_form.html?country=12&sub_type=1" >Pakistan</a>'
menu10[13]='<a href="' + httpsvar + '/formfile/student_form.html?country=13&sub_type=1">Philippines</a>'
menu10[14]='<a href="' + httpsvar + '/formfile/student_form.html?country=14&sub_type=1">Singapore</a>'
menu10[15]='<a href="' + httpsvar + '/formfile/student_form.html?country=15&sub_type=1">Sri Lanka</a>'
menu10[16]='<a href="' + httpsvar + '/formfile/student_form.html?country=16&sub_type=1">Taiwan</a>'
menu10[17]='<a href="' + httpsvar + '/formfile/student_form.html?country=17&sub_type=1" >Thailand</a>'
menu10[18]='<a href="' + httpsvar + '/formfile/student_form.html?country=18&sub_type=1">Vietnam</a>'
menu10[19]='<a href="' + httpsvar + '/formfile/student_form.html?country=19&sub_type=1">Other Asian Countries</a>'
menu10[20]='<a href="' + httpsvar + '/formfile/student_form.html?country=20&sub_type=1">Europe</a>'
menu10[21]='<a href="' + httpsvar + '/formfile/student_form.html?country=21&sub_type=1" >North America</a>'
menu10[22]='<a href="' + httpsvar + '/formfile/student_form.html?country=22&sub_type=1">Rest of the World</a>'
//Contents for submenu for "Gift Subscription"
var menu11=new Array()
menu11[0]='<a href="' + httpsvar + '/giftform?country=australia" >Australia</a>'
menu11[1]='<a href="' + httpsvar + '/giftform?country=brunei">Brunei</a>'
menu11[2]='<a href="' + httpsvar + '/giftform?country=china">China</a>'
menu11[3]='<a href="' + httpsvar + '/giftform?country=hk">Hong Kong</a>'
menu11[4]='<a href="' + httpsvar + '/subhome/subscription_india" >India</a>'
menu11[5]='<a href="' + httpsvar + '/giftform?country=indonesia">Indonesia</a>'
menu11[6]='<a href="' + httpsvar + '/giftform?country=japan">Japan</a>'
menu11[7]='<a href="' + httpsvar + '/giftform?country=korea">Korea</a>'
menu11[8]='<a href="' + httpsvar + '/giftform?country=malaysia" >Malaysia</a>'
menu11[9]='<a href="' + httpsvar + '/giftform?country=macau">Macau</a>'
menu11[10]='<a href="' + httpsvar + '/giftform?country=new_zealand">New Zealand</a>'
menu11[11]='<a href="' + httpsvar + '/giftform?country=pacific_islands">Pacific Islands</a>'
menu11[12]='<a href="' + httpsvar + '/giftform?country=pakistan" >Pakistan</a>'
menu11[13]='<a href="' + httpsvar + '/giftform?country=philippines">Philippines</a>'
menu11[14]='<a href="' + httpsvar + '/giftform?country=singapore">Singapore</a>'
menu11[15]='<a href="' + httpsvar + '/giftform?country=sri_lanka">Sri Lanka</a>'
menu11[16]='<a href="' + httpsvar + '/giftform?country=taiwan">Taiwan</a>'
menu11[17]='<a href="' + httpsvar + '/giftform?country=thailand" >Thailand</a>'
menu11[18]='<a href="' + httpsvar + '/giftform?country=vietnam">Vietnam</a>'
menu11[19]='<a href="' + httpsvar + '/giftform?country=other_asian_countries">Other Asian Countries</a>'
menu11[20]='<a href="' + httpsvar + '/giftform?country=europe">Europe</a>'
menu11[21]='<a href="' + httpsvar + '/giftform?country=north_america" >North America</a>'
menu11[22]='<a href="' + httpsvar + '/giftform?country=rest_of_the_world">Rest of the World</a>'

var menu12=new Array()
menu12[0]='<a href="' + httpvar + '/masters/taiwan_ntu.html">Taiwan</a>'

var disappeardelay=250  //menu disappear speed onMouseout (in miliseconds)
var horizontaloffset=2 //horizontal offset of menu from default location. (0-5 is a good value)

/////No further editting needed

var ie4=document.all
var ns6=document.getElementById&&!document.all
delayhidemenu()
delayhidemenu2()
if (ie4||ns6)
{
	document.write('<div id="dropmenudiv" style="visibility:hidden;width: 160px" onMouseover="clearhidemenu()" onMouseout="dynamichide(event)"></div>')
	document.write('<div id="dropmenudiv2" style="visibility:hidden;width: 160px" onMouseover="clearhidemenu2()" onMouseout="dynamichide2(event)"></div>')
}
function getposOffset(what, offsettype){
var totaloffset=(offsettype=="left")? what.offsetLeft : what.offsetTop;
var parentEl=what.offsetParent;
while (parentEl!=null){
totaloffset=(offsettype=="left")? totaloffset+parentEl.offsetLeft : totaloffset+parentEl.offsetTop;
parentEl=parentEl.offsetParent;
}
return totaloffset;
}
function showhide(obj, e, visible, hidden, menuwidth){
if (ie4||ns6)
dropmenuobj.style.left=dropmenuobj.style.top=-500
dropmenuobj.widthobj=dropmenuobj.style
dropmenuobj.widthobj.width=menuwidth
if (e.type=="click" && obj.visibility==hidden || e.type=="mouseover")
{
	obj.visibility=visible
}
else if (e.type=="click")
{
	obj.visibility=hidden
}
}
function iecompattest(){
return (document.compatMode && document.compatMode!="BackCompat")? document.documentElement : document.body
}
function clearbrowseredge(obj, whichedge){
var edgeoffset=0
if (whichedge=="rightedge"){
var windowedge=ie4 && !window.opera? iecompattest().scrollLeft+iecompattest().clientWidth-15 : window.pageXOffset+window.innerWidth-15
dropmenuobj.contentmeasure=dropmenuobj.offsetWidth
if (windowedge-dropmenuobj.x-obj.offsetWidth < dropmenuobj.contentmeasure)
edgeoffset=dropmenuobj.contentmeasure+obj.offsetWidth
}
else{
var topedge=ie4 && !window.opera? iecompattest().scrollTop : window.pageYOffset
var windowedge=ie4 && !window.opera? iecompattest().scrollTop+iecompattest().clientHeight-15 : window.pageYOffset+window.innerHeight-18
dropmenuobj.contentmeasure=dropmenuobj.offsetHeight
if (windowedge-dropmenuobj.y < dropmenuobj.contentmeasure){ //move menu up?
edgeoffset=dropmenuobj.contentmeasure-obj.offsetHeight
if ((dropmenuobj.y-topedge)<dropmenuobj.contentmeasure) //up no good either? (position at top of viewable window then)
edgeoffset=dropmenuobj.y
}
}
return edgeoffset
}
function populatemenu(what){
if (ie4||ns6)
dropmenuobj.innerHTML=what.join("")
}
function dropdownmenu(obj, e, menucontents, menuwidth){
if (window.event) event.cancelBubble=true
else if (e.stopPropagation) e.stopPropagation()
clearhidemenu()
dropmenuobj=document.getElementById? document.getElementById("dropmenudiv") : dropmenudiv
if ( location.href.indexOf("subscribe2.html") >0 )
{
	document.form1.select1.style.visibility="hidden"; 
}
populatemenu(menucontents)
if (ie4||ns6){
showhide(dropmenuobj.style, e, "visible", "hidden", menuwidth)
dropmenuobj.x=getposOffset(obj, "left")
dropmenuobj.y=getposOffset(obj, "top")
dropmenuobj.style.left=dropmenuobj.x-clearbrowseredge(obj, "rightedge")+obj.offsetWidth+horizontaloffset+"px"
dropmenuobj.style.top=dropmenuobj.y-clearbrowseredge(obj, "bottomedge")+"px"
}
return clickreturnvalue()
}
function clickreturnvalue(){
if (ie4||ns6) return false
else return true
}
function contains_ns6(a, b) {
while (b.parentNode)
if ((b = b.parentNode) == a)
return true;
return false;
}
function dynamichide(e){
if (ie4&&!dropmenuobj.contains(e.toElement))
delayhidemenu()
else if (ns6&&e.currentTarget!= e.relatedTarget&& !contains_ns6(e.currentTarget, e.relatedTarget))
delayhidemenu()
}
function hidemenu(e){
if (typeof dropmenuobj!="undefined"){
if (ie4||ns6)
dropmenuobj.style.visibility="hidden"
if ( location.href.indexOf("subscribe2.html") >0 )
{
	document.form1.select1.style.visibility="visible"; 
}
}
}
function delayhidemenu(){
if (ie4||ns6)
delayhide=setTimeout("hidemenu()",disappeardelay)
}
function clearhidemenu(){
if (typeof delayhide!="undefined")
clearTimeout(delayhide)
}
function jump_to_bookmark(bookmark) {
var l;
    l = document.location.protocol+"//"+document.location.hostname+document.location.pathname+"?source_code="+source_code + "#"+bookmark
    document.location = l;
}

function showhide2(obj, e, visible, hidden, menuwidth)
{
	if (ie4||ns6)
		dropmenuobj2.style.left=dropmenuobj2.style.top=-500
	dropmenuobj2.widthobj=dropmenuobj2.style
	dropmenuobj2.widthobj.width=menuwidth
	if (e.type=="click" && obj.visibility==hidden || e.type=="mouseover")
	{
		obj.visibility=visible
	}
	else if (e.type=="click")
	{
		obj.visibility=hidden
	}
}
function populatemenu2(what)
{
	if (ie4||ns6)
		dropmenuobj2.innerHTML=what.join("")
}
function dropdownmenu2(obj, e, menucontents, menuwidth)
{
	if (window.event) 
		event.cancelBubble=true
	else if (e.stopPropagation) 
		e.stopPropagation()
	clearhidemenu2()
	dropmenuobj2=document.getElementById? document.getElementById("dropmenudiv2") : dropmenudiv2
	if ( location.href.indexOf("subscribe2.html") >0 )
	{
		document.form1.select1.style.visibility="hidden"; 
	}
	populatemenu2(menucontents)
	if (ie4||ns6)
	{
		showhide2(dropmenuobj2.style, e, "visible", "hidden", menuwidth)
		dropmenuobj2.x=getposOffset(obj, "left")
		dropmenuobj2.y=getposOffset(obj, "top")
		dropmenuobj2.style.left=dropmenuobj2.x-clearbrowseredge(obj, "rightedge")+obj.offsetWidth+horizontaloffset+"px"
		dropmenuobj2.style.top=dropmenuobj2.y-clearbrowseredge(obj, "bottomedge")+"px"
	}
	return clickreturnvalue()
}
function dynamichide2(e)
{
	if (ie4&&!dropmenuobj2.contains(e.toElement))
	{
		delayhidemenu2()
		delayhidemenu()
	}
	else if (ns6&&e.currentTarget!= e.relatedTarget&& !contains_ns6(e.currentTarget, e.relatedTarget))
	{
		delayhidemenu2()
		delayhidemenu()
	}
}
function hidemenu2(e)
{
	if (typeof dropmenuobj2!="undefined")
	{
		if (ie4||ns6)
		{
			dropmenuobj2.style.visibility="hidden"
		}
		if ( location.href.indexOf("subscribe2.html") >0 )
		{
			document.form1.select1.style.visibility="visible"; 
		}
	}
}
function delayhidemenu2()
{
	if (ie4||ns6)
		delayhide2=setTimeout("hidemenu2()",disappeardelay)
}
function clearhidemenu2()
{
	if (typeof delayhide2!="undefined")
	{
		clearTimeout(delayhide2)
		clearTimeout(delayhide)
	}
}
function jump_to_bookmark(bookmark) {
var l;
    l = document.location.protocol+"//"+document.location.hostname+document.location.pathname+"?source_code="+source_code + "#"+bookmark
    document.location = l;
//    document.write(l);
}


