




var MHeight = 0;


var isDOMxx = (document.getElementById ? true : false);
var isIE4xx = ((document.all && !isDOMxx) ? true : false);
var isNS4xx = (document.layers ? true : false);

var menu = new Array();
var litNow = new Array();
var popTimerxx = 0;

var widthL1 = 170;
var widthRemain = 760 - widthL1;

var OverL1 = '#C7DBFF', BackL1 = '#ADCBFF';
var OverL2 = '#7AABFF', BackL2 = '#C7DBFF';
var BackL3 = '#dd7722';
var BackL4 = '#eea000';
var BackL5 = '#3080dd';
var BackL6 = '#2060bb';
var textL1 = '#ffffff';
var textL2 = '#222222';

var basepx = 125;
var heightL1 = 25;
var _widthL2 = '215';
var widthL2;
if(_widthL2 == ""||_widthL2 == null||isNaN(_widthL2)) widthL2 = 200;
else widthL2 = parseInt(_widthL2);
var totalHeight = 0;


var popOldWidth = window.innerWidth;

var dot = '<td align=center valign=top width=14><img src="../../resources/images/en/dot_01.gif" border=0 ';
var HOME = '<td align=center valign=top width=14><img src="../../resources/images/en/dot_01.gif" border=0 ';
var space = '<td align=center valign=top width=2><img src="../../resources/images/en/dot_01.gif" border=0  ';

function bg() {
 if(navigator.appName=="Microsoft Internet Explorer") {
  } else {
  }
}

function writeMenus() {
if (!isDOMxx && !isIE4xx && !isNS4xx) return;

for (currMenu = 0; currMenu < menu.length; currMenu++) with (menu[currMenu][0]) {
var str = '', itemX = 0, itemY = 0;

for (currItem = 1; currItem < menu[currMenu].length; currItem++) with (menu[currMenu][currItem]) {
var itemID = 'menu' + currMenu + 'item' + currItem;
var w = (isVert ? width : length);
var h = (isVert ? length : width);

if (isDOMxx || isIE4xx) {
str += '<div id="' + itemID + '" style="position: absolute; left: ' + itemX + '; top: ' + itemY + '; width: ' + w + '; height: ' + h + '; visibility: inherit; ';
if (backCol) str += 'background: ' + backCol + '; ';
str += '" ';
}
if (isNS4xx) {
str += '<layer id="' + itemID + '" left="' + itemX + '" top="' + itemY + '" width="' +  w + '" height="' + h + '" visibility="inherit" ';
if (backCol) str += 'bgcolor="' + backCol + '" ';
}
if (borderClass) str += 'class="' + borderClass + '" ';

str += 'onMouseOver="popOver(' + currMenu + ',' + currItem + ')" onMouseOut="popOut(' + currMenu + ',' + currItem + ')">';

str += '<table id="MENU" width="' + (w - 8) + '" border="0" valign=top cellspacing="0" cellpadding="' + (!isNS4xx && borderClass ? 3 : 0) + '">' + "<tr onmouseout=clearstatus(); onmouseover=cursorhand(this,'"+href+"'); onclick=gourl('"+href+"');>"  + image + '<td align="left" height="' + (h - 7) + '">' + '<a class="' + textClass + '" href="' + href + '"' + (frame ? ' target="' + frame + '">' : '>') + text + '</a></td>';
if (target > 0) {

menu[target][0].parentMenu = currMenu;
menu[target][0].parentItem = currItem;

if (popInd) str += '<td class="' + textClass + '" valign=top align="right">' + popInd + '</td>';
}
str += '</tr></table>' + (isNS4xx ? '</layer>' : '</div>');
if (isVert) itemY += length + spacing;
else itemX += length + spacing;
}
if (isDOMxx) {
var newDiv = document.createElement('div');
document.getElementsByTagName('body').item(0).appendChild(newDiv);
newDiv.innerHTML = str;
ref = newDiv.style;
ref.position = 'absolute';
ref.visibility = 'hidden';
ref.valign='top';
}

if (isIE4xx) {
document.body.insertAdjacentHTML('beforeEnd', '<div id="menu' + currMenu + 'div" ' + 'style="position: absolute; visibility: hidden">' + str + '</div>');
ref = getSty('menu' + currMenu + 'div');
}

if (isNS4xx) {
ref = new Layer(0);
ref.document.write(str);
ref.document.close();
}

for (currItem = 1; currItem < menu[currMenu].length; currItem++) {
itemName = 'menu' + currMenu + 'item' + currItem;
if (isDOMxx || isIE4xx) menu[currMenu][currItem].ref = getSty(itemName);
if (isNS4xx) menu[currMenu][currItem].ref = ref.document[itemName];
   }
}
with(menu[0][0]) {
ref.left = x;
ref.top = y;
ref.visibility = 'visible';
   }

//document.getElementByName("menuRow").height=totalHeight;

}

/* function Item(image, text, href, frame, length, spacing, target) */
/* Edit Menu Here -- Start */


	var enght;
	var enght_num;
	var dtl_enght;
	var dtl_enght_num;
	menu[0] = new Array();
	menu[0][0] = new Menu(true, '', 0, basepx, widthL1, OverL1, BackL1, 'itemBorder', 'itemText');

	
	enght = '1';
	if (enght == "" || enght == null || isNaN(enght)) enght_num = 1;
	else enght_num = parseInt(enght);
	
	
	menu[0][1] = new Item1(dot, "What's New", "../../en/whats_new/whats_new.html", '', enght_num, 0, 1);
	totalHeight = totalHeight + heightL1*enght_num;
	menu[1] = new Array();
	menu[1][0] = new Menu(true, '>', widthL1, 0, widthL2, OverL2, BackL2, 'itemBorder', 'itemText');
	
	
	dtl_enght = '1';
	if (dtl_enght == "" || dtl_enght == null) dtl_enght_num = 1;
	else dtl_enght_num = parseInt(dtl_enght);
	menu[1][1] = new Item2(space, "Press Release", '../../en/whats_new/press_release.html', '', dtl_enght_num, 0, 0);
	
	
	dtl_enght = '1';
	if (dtl_enght == "" || dtl_enght == null) dtl_enght_num = 1;
	else dtl_enght_num = parseInt(dtl_enght);
	menu[1][2] = new Item2(space, "Latest Agenda", '../../en/whats_new/agenda.html', '', dtl_enght_num, 0, 0);
	
	
	dtl_enght = '1';
	if (dtl_enght == "" || dtl_enght == null) dtl_enght_num = 1;
	else dtl_enght_num = parseInt(dtl_enght);
	menu[1][3] = new Item2(space, "Latest Gist of Decisions", '../../en/whats_new/gist.html', '', dtl_enght_num, 0, 0);
	
	
	dtl_enght = '1';
	if (dtl_enght == "" || dtl_enght == null) dtl_enght_num = 1;
	else dtl_enght_num = parseInt(dtl_enght);
	menu[1][4] = new Item2(space, "Latest Minutes", '../../en/whats_new/minutes.html', '', dtl_enght_num, 0, 0);
	
	
	dtl_enght = '2';
	if (dtl_enght == "" || dtl_enght == null) dtl_enght_num = 1;
	else dtl_enght_num = parseInt(dtl_enght);
	menu[1][5] = new Item2(space, "New Draft Plans Inviting Submissions", '../../en/whats_new/new_draft_plan.html', '', dtl_enght_num, 0, 0);
	
	
	dtl_enght = '3';
	if (dtl_enght == "" || dtl_enght == null) dtl_enght_num = 1;
	else dtl_enght_num = parseInt(dtl_enght);
	menu[1][6] = new Item2(space, "New Applications and Further Information Inviting Comments", '../../en/whats_new/new_application.html', '', dtl_enght_num, 0, 0);
	
	
	dtl_enght = '2';
	if (dtl_enght == "" || dtl_enght == null) dtl_enght_num = 1;
	else dtl_enght_num = parseInt(dtl_enght);
	menu[1][7] = new Item2(space, "New Comments on Applications Available for Public Inspection", '../../en/whats_new/application_comment.html', '', dtl_enght_num, 0, 0);
	
	
	
	

	
	enght = '1';
	if (enght == "" || enght == null || isNaN(enght)) enght_num = 1;
	else enght_num = parseInt(enght);
	
	
	menu[0][2] = new Item1(dot, "About Us", "../../en/about_us/about_us.html", '', enght_num, 0, 2);
	totalHeight = totalHeight + heightL1*enght_num;
	menu[2] = new Array();
	menu[2][0] = new Menu(true, '>', widthL1, 0, widthL2, OverL2, BackL2, 'itemBorder', 'itemText');
	
	
	dtl_enght = '1';
	if (dtl_enght == "" || dtl_enght == null) dtl_enght_num = 1;
	else dtl_enght_num = parseInt(dtl_enght);
	menu[2][1] = new Item2(space, "Introduction", '../../en/about_us/intro.html', '', dtl_enght_num, 0, 0);
	
	
	dtl_enght = '1';
	if (dtl_enght == "" || dtl_enght == null) dtl_enght_num = 1;
	else dtl_enght_num = parseInt(dtl_enght);
	menu[2][2] = new Item2(space, "Membership", '../../en/about_us/member.html', '', dtl_enght_num, 0, 0);
	
	
	dtl_enght = '1';
	if (dtl_enght == "" || dtl_enght == null) dtl_enght_num = 1;
	else dtl_enght_num = parseInt(dtl_enght);
	menu[2][3] = new Item2(space, "Annual Reports", '../../en/about_us/annual_rpt.html', '', dtl_enght_num, 0, 0);
	
	
	dtl_enght = '1';
	if (dtl_enght == "" || dtl_enght == null) dtl_enght_num = 1;
	else dtl_enght_num = parseInt(dtl_enght);
	menu[2][4] = new Item2(space, "Procedure and Practice", '../../en/about_us/procedure.html', '', dtl_enght_num, 0, 0);
	
	
	
	

	
	enght = '1';
	if (enght == "" || enght == null || isNaN(enght)) enght_num = 1;
	else enght_num = parseInt(enght);
	
	
	menu[0][3] = new Item1(dot, "Press Release", "../../en/press_release/press_release.html", '', enght_num, 0, 3);
	totalHeight = totalHeight + heightL1*enght_num;
	menu[3] = new Array();
	menu[3][0] = new Menu(true, '>', widthL1, 0, widthL2, OverL2, BackL2, 'itemBorder', 'itemText');
	
	
	dtl_enght = '1';
	if (dtl_enght == "" || dtl_enght == null) dtl_enght_num = 1;
	else dtl_enght_num = parseInt(dtl_enght);
	menu[3][1] = new Item2(space, "Plan Publication", '../../en/press_release/publication.html', '', dtl_enght_num, 0, 0);
	
	
	dtl_enght = '1';
	if (dtl_enght == "" || dtl_enght == null) dtl_enght_num = 1;
	else dtl_enght_num = parseInt(dtl_enght);
	menu[3][2] = new Item2(space, "Other Topics", '../../en/press_release/others.html', '', dtl_enght_num, 0, 0);
	
	
	
	

	
	enght = '3';
	if (enght == "" || enght == null || isNaN(enght)) enght_num = 1;
	else enght_num = parseInt(enght);
	
	
	menu[0][4] = new Item1(dot, "Forms, Guidelines, Technical Documents and Reference Materials", "../../en/forms/forms.html", '', enght_num, 0, 4);
	totalHeight = totalHeight + heightL1*enght_num;
	menu[4] = new Array();
	menu[4][0] = new Menu(true, '>', widthL1, 0, widthL2, OverL2, BackL2, 'itemBorder', 'itemText');
	
	
	dtl_enght = '1';
	if (dtl_enght == "" || dtl_enght == null) dtl_enght_num = 1;
	else dtl_enght_num = parseInt(dtl_enght);
	menu[4][1] = new Item2(space, "Town Planning Ordinance", '../../en/forms/ordinance.html', '', dtl_enght_num, 0, 0);
	
	
	dtl_enght = '1';
	if (dtl_enght == "" || dtl_enght == null) dtl_enght_num = 1;
	else dtl_enght_num = parseInt(dtl_enght);
	menu[4][2] = new Item2(space, "TPB Guidelines", '../../en/forms/guideline.html', '', dtl_enght_num, 0, 0);
	
	
	dtl_enght = '1';
	if (dtl_enght == "" || dtl_enght == null) dtl_enght_num = 1;
	else dtl_enght_num = parseInt(dtl_enght);
	menu[4][3] = new Item2(space, "Technical Documents", '../../en/forms/techdoc.html', '', dtl_enght_num, 0, 0);
	
	
	dtl_enght = '1';
	if (dtl_enght == "" || dtl_enght == null) dtl_enght_num = 1;
	else dtl_enght_num = parseInt(dtl_enght);
	menu[4][4] = new Item2(space, "Forms & Guidance Notes", '../../en/forms/forms_related.html', '', dtl_enght_num, 0, 0);
	
	
	dtl_enght = '1';
	if (dtl_enght == "" || dtl_enght == null) dtl_enght_num = 1;
	else dtl_enght_num = parseInt(dtl_enght);
	menu[4][5] = new Item2(space, "Master Schedule of Notes", '../../en/forms/master_schedule.html', '', dtl_enght_num, 0, 0);
	
	
	dtl_enght = '1';
	if (dtl_enght == "" || dtl_enght == null) dtl_enght_num = 1;
	else dtl_enght_num = parseInt(dtl_enght);
	menu[4][6] = new Item2(space, "Definition of Terms", '../../en/forms/definition.html', '', dtl_enght_num, 0, 0);
	
	
	dtl_enght = '1';
	if (dtl_enght == "" || dtl_enght == null) dtl_enght_num = 1;
	else dtl_enght_num = parseInt(dtl_enght);
	menu[4][7] = new Item2(space, "Information Pamphlets", '../../en/forms/info_pamphlet.html', '', dtl_enght_num, 0, 0);
	
	
	
	

	
	enght = '1';
	if (enght == "" || enght == null || isNaN(enght)) enght_num = 1;
	else enght_num = parseInt(enght);
	
	
	menu[0][5] = new Item1(dot, "List of Plans", "../../en/list_of_plans/list_of_plans.html", '', enght_num, 0, 5);
	totalHeight = totalHeight + heightL1*enght_num;
	menu[5] = new Array();
	menu[5][0] = new Menu(true, '>', widthL1, 0, widthL2, OverL2, BackL2, 'itemBorder', 'itemText');
	
	
	dtl_enght = '1';
	if (dtl_enght == "" || dtl_enght == null) dtl_enght_num = 1;
	else dtl_enght_num = parseInt(dtl_enght);
	menu[5][1] = new Item2(space, "Introduction", '../../en/list_of_plans/intro.html', '', dtl_enght_num, 0, 0);
	
	
	dtl_enght = '2';
	if (dtl_enght == "" || dtl_enght == null) dtl_enght_num = 1;
	else dtl_enght_num = parseInt(dtl_enght);
	menu[5][2] = new Item2(space, "Coverage of OZPs and DPA Plans", '../../en/list_of_plans/coverage.html', '', dtl_enght_num, 0, 0);
	
	
	dtl_enght = '1';
	if (dtl_enght == "" || dtl_enght == null) dtl_enght_num = 1;
	else dtl_enght_num = parseInt(dtl_enght);
	menu[5][3] = new Item2(space, "Schedule of Plans", '../../en/list_of_plans/schedule_plan.html', '', dtl_enght_num, 0, 0);
	
	
	dtl_enght = '1';
	if (dtl_enght == "" || dtl_enght == null) dtl_enght_num = 1;
	else dtl_enght_num = parseInt(dtl_enght);
	menu[5][4] = new Item2(space, "Contents of Plans", '../../en/list_of_plans/content_plan.html', '', dtl_enght_num, 0, 0);
	
	
	
	

	
	enght = '1';
	if (enght == "" || enght == null || isNaN(enght)) enght_num = 1;
	else enght_num = parseInt(enght);
	
	
	menu[0][6] = new Item1(dot, "Plan-making", "../../en/plan_making/plan_making.html", '', enght_num, 0, 6);
	totalHeight = totalHeight + heightL1*enght_num;
	menu[6] = new Array();
	menu[6][0] = new Menu(true, '>', widthL1, 0, widthL2, OverL2, BackL2, 'itemBorder', 'itemText');
	
	
	dtl_enght = '1';
	if (dtl_enght == "" || dtl_enght == null) dtl_enght_num = 1;
	else dtl_enght_num = parseInt(dtl_enght);
	menu[6][1] = new Item2(space, "How to Participate?", '../../en/plan_making/participate.html', '', dtl_enght_num, 0, 0);
	
	
	dtl_enght = '3';
	if (dtl_enght == "" || dtl_enght == null) dtl_enght_num = 1;
	else dtl_enght_num = parseInt(dtl_enght);
	menu[6][2] = new Item2(space, "Plans Currently Inviting Representations/Comments/ Further Representations", '../../en/plan_making/draft_plan.html', '', dtl_enght_num, 0, 0);
	
	
	dtl_enght = '5';
	if (dtl_enght == "" || dtl_enght == null) dtl_enght_num = 1;
	else dtl_enght_num = parseInt(dtl_enght);
	menu[6][3] = new Item2(space, "Plans Currently Inviting Objections/Further Objections (under Pre-amended Town Planning Ordinance)", '../../en/plan_making/draft_plan_inv_obj.html', '', dtl_enght_num, 0, 0);
	
	
	dtl_enght = '4';
	if (dtl_enght == "" || dtl_enght == null) dtl_enght_num = 1;
	else dtl_enght_num = parseInt(dtl_enght);
	menu[6][4] = new Item2(space, "Representations/Comments/ Further Representations Currently Available for Public Inspection", '../../en/plan_making/submission_insp.html', '', dtl_enght_num, 0, 0);
	
	
	dtl_enght = '5';
	if (dtl_enght == "" || dtl_enght == null) dtl_enght_num = 1;
	else dtl_enght_num = parseInt(dtl_enght);
	menu[6][5] = new Item2(space, "Summary of Objections/Futher Objections(under Pre-amended Town Planning Ordinance)", '../../en/plan_making/draft_plan_obj.html', '', dtl_enght_num, 0, 0);
	
	
	dtl_enght = '1';
	if (dtl_enght == "" || dtl_enght == null) dtl_enght_num = 1;
	else dtl_enght_num = parseInt(dtl_enght);
	menu[6][6] = new Item2(space, "Planning for Victoria Harbour", '../../en/plan_making/victoriaharbour.html', '', dtl_enght_num, 0, 0);
	
	
	
	

	
	enght = '2';
	if (enght == "" || enght == null || isNaN(enght)) enght_num = 1;
	else enght_num = parseInt(enght);
	
	
	menu[0][7] = new Item1(dot, "Planning Applications", "../../en/plan_application/plan_application.html", '', enght_num, 0, 7);
	totalHeight = totalHeight + heightL1*enght_num;
	menu[7] = new Array();
	menu[7][0] = new Menu(true, '>', widthL1, 0, widthL2, OverL2, BackL2, 'itemBorder', 'itemText');
	
	
	dtl_enght = '1';
	if (dtl_enght == "" || dtl_enght == null) dtl_enght_num = 1;
	else dtl_enght_num = parseInt(dtl_enght);
	menu[7][1] = new Item2(space, "How to Apply?", '../../en/plan_application/apply.html', '', dtl_enght_num, 0, 0);
	
	
	dtl_enght = '2';
	if (dtl_enght == "" || dtl_enght == null) dtl_enght_num = 1;
	else dtl_enght_num = parseInt(dtl_enght);
	menu[7][2] = new Item2(space, "How to Make Comments?", '../../en/plan_application/make_comment.html', '', dtl_enght_num, 0, 0);
	
	
	dtl_enght = '3';
	if (dtl_enght == "" || dtl_enght == null) dtl_enght_num = 1;
	else dtl_enght_num = parseInt(dtl_enght);
	menu[7][3] = new Item2(space, "Applications and Further Information Currently Inviting Comments", '../../en/plan_application/application_comment.html', '', dtl_enght_num, 0, 0);
	
	
	dtl_enght = '3';
	if (dtl_enght == "" || dtl_enght == null) dtl_enght_num = 1;
	else dtl_enght_num = parseInt(dtl_enght);
	menu[7][4] = new Item2(space, "Applications and Comments Currently Available for Public Inspection", '../../en/plan_application/application_insp.html', '', dtl_enght_num, 0, 0);
	
	
	dtl_enght = '4';
	if (dtl_enght == "" || dtl_enght == null) dtl_enght_num = 1;
	else dtl_enght_num = parseInt(dtl_enght);
	menu[7][5] = new Item2(space, "Urban Renewal Authority Development Schemes Currently Inviting Comments", '../../en/plan_application/development_comment.html', '', dtl_enght_num, 0, 0);
	
	
	dtl_enght = '4';
	if (dtl_enght == "" || dtl_enght == null) dtl_enght_num = 1;
	else dtl_enght_num = parseInt(dtl_enght);
	menu[7][6] = new Item2(space, "Urban Renewal Authority Development Schemes Currently Available For Public Inspection", '../../en/plan_application/development_insp.html', '', dtl_enght_num, 0, 0);
	
	
	dtl_enght = '4';
	if (dtl_enght == "" || dtl_enght == null) dtl_enght_num = 1;
	else dtl_enght_num = parseInt(dtl_enght);
	menu[7][7] = new Item2(space, "Applications for Planning Permission (under pre-amended Town Planning Ordinance)", '../../en/plan_application/application_permission.html', '', dtl_enght_num, 0, 0);
	
	
	dtl_enght = '4';
	if (dtl_enght == "" || dtl_enght == null) dtl_enght_num = 1;
	else dtl_enght_num = parseInt(dtl_enght);
	menu[7][8] = new Item2(space, "Requests for Amendment to Statutory Plan (under pre-amended Town Planning Ordinance)", '../../en/plan_application/request_amend.html', '', dtl_enght_num, 0, 0);
	
	
	dtl_enght = '3';
	if (dtl_enght == "" || dtl_enght == null) dtl_enght_num = 1;
	else dtl_enght_num = parseInt(dtl_enght);
	menu[7][9] = new Item2(space, "Records of Previous Planning Applications (since 1 January 1990)", '../../en/plan_application/records.html', '', dtl_enght_num, 0, 0);
	
	
	
	

	
	enght = '1';
	if (enght == "" || enght == null || isNaN(enght)) enght_num = 1;
	else enght_num = parseInt(enght);
	
	
	menu[0][8] = new Item1(dot, "Meetings", "../../en/meetings/meetings.html", '', enght_num, 0, 8);
	totalHeight = totalHeight + heightL1*enght_num;
	menu[8] = new Array();
	menu[8][0] = new Menu(true, '>', widthL1, 0, widthL2, OverL2, BackL2, 'itemBorder', 'itemText');
	
	
	dtl_enght = '2';
	if (dtl_enght == "" || dtl_enght == null) dtl_enght_num = 1;
	else dtl_enght_num = parseInt(dtl_enght);
	menu[8][1] = new Item2(space, "Matters Related to Open Meeting", '../../en/meetings/open_meeting.html', '', dtl_enght_num, 0, 0);
	
	
	dtl_enght = '2';
	if (dtl_enght == "" || dtl_enght == null) dtl_enght_num = 1;
	else dtl_enght_num = parseInt(dtl_enght);
	menu[8][2] = new Item2(space, "Town Planning Board Meetings", '../../en/meetings/tpb_meeting.html', '', dtl_enght_num, 0, 0);
	
	
	dtl_enght = '2';
	if (dtl_enght == "" || dtl_enght == null) dtl_enght_num = 1;
	else dtl_enght_num = parseInt(dtl_enght);
	menu[8][3] = new Item2(space, "Metro Planning Committee Meetings", '../../en/meetings/mpc_meeting.html', '', dtl_enght_num, 0, 0);
	
	
	dtl_enght = '3';
	if (dtl_enght == "" || dtl_enght == null) dtl_enght_num = 1;
	else dtl_enght_num = parseInt(dtl_enght);
	menu[8][4] = new Item2(space, "Rural and New Town Planning Committee Meetings", '../../en/meetings/rntpc_meeting.html', '', dtl_enght_num, 0, 0);
	
	
	dtl_enght = '2';
	if (dtl_enght == "" || dtl_enght == null) dtl_enght_num = 1;
	else dtl_enght_num = parseInt(dtl_enght);
	menu[8][5] = new Item2(space, "Representation Hearing Committee Meetings", '../../en/meetings/rhc_meeting.html', '', dtl_enght_num, 0, 0);
	
	
	
	

	
	enght = '1';
	if (enght == "" || enght == null || isNaN(enght)) enght_num = 1;
	else enght_num = parseInt(enght);
	
	
	menu[0][9] = new Item1(dot, "Links", "../../en/links/links.html", '', enght_num, 0, 0);
	totalHeight = totalHeight + heightL1*enght_num;
	
	

	
	enght = '1';
	if (enght == "" || enght == null || isNaN(enght)) enght_num = 1;
	else enght_num = parseInt(enght);
	
	
	menu[0][10] = new Item1(dot, "Contact Us", "../../en/contact_us/contact_us.html", '', enght_num, 0, 0);
	totalHeight = totalHeight + heightL1*enght_num;
	
	


/* Edit Menu Here -- End */

nsResizeHandler = new Function('if (popOldWidth != window.innerWidth) location.reload()');

if (isNS4xx) document.captureEvents(Event.CLICK);
document.onclick = clickHandle;

function AddMenuHeight(y) {
        MHeight = MHeight + y - 1;
}

function cursorhand(x,y) {
	x.style.cursor = 'hand';
        window.status = y;
}

function clearstatus() {
 	window.status='';
}

function gourl(x) {
	window.location = x;
}

function getRef(id) {
if (isDOMxx) return document.getElementById(id);
if (isIE4xx) return document.all[id];
if (isNS4xx) return document.layers[id];
}

function getSty(id) {
return (isNS4xx ? getRef(id) : getRef(id).style);
}

function popOver(menuNum, itemNum) {
clearTimeout(popTimerxx);
hideAllBut(menuNum);
litNow = getTree(menuNum, itemNum);
changeCol(litNow, true);
targetNum = menu[menuNum][itemNum].target;
if (targetNum > 0) {
thisX = parseInt(menu[menuNum][0].ref.left) + parseInt(menu[menuNum][itemNum].ref.left);
thisY = parseInt(menu[menuNum][0].ref.top) + parseInt(menu[menuNum][itemNum].ref.top);
with (menu[targetNum][0].ref) {
left = parseInt(thisX + menu[targetNum][0].x);
top = parseInt(thisY + menu[targetNum][0].y);
visibility = 'visible';
      }
   }
}

function popOut(menuNum, itemNum) {
if ((menuNum == 0) && !menu[menuNum][itemNum].target)
hideAllBut(0)
else
popTimerxx = setTimeout('hideAllBut(0)', 500);
}

function getTree(menuNum, itemNum) {

itemArray = new Array(menu.length);

while(1) {
itemArray[menuNum] = itemNum;

if (menuNum == 0) return itemArray;
itemNum = menu[menuNum][0].parentItem;
menuNum = menu[menuNum][0].parentMenu;
   }
}

function changeCol(changeArray, isOver) {
for (menuCount = 0; menuCount < changeArray.length; menuCount++) {
if (changeArray[menuCount]) {
newCol = isOver ? menu[menuCount][0].overCol : menu[menuCount][0].backCol;
// Change the colours of the div/layer background.
with (menu[menuCount][changeArray[menuCount]].ref) {
if (isNS4xx) bgColor = newCol;
else backgroundColor = newCol;
         }
      }
   }
}
function hideAllBut(menuNum) {
var keepMenus = getTree(menuNum, 1);
for (count = 0; count < menu.length; count++)
if (!keepMenus[count])
menu[count][0].ref.visibility = 'hidden';
changeCol(litNow, false);
}

function Menu(isVert, popInd, x, y, width, overCol, backCol, borderClass, textClass) {

this.isVert = isVert;

this.popInd = popInd;

this.x = x;
this.y = y;
this.width = width;
this.overCol = overCol;
this.backCol = backCol;
this.borderClass = borderClass;
this.textClass = "menu";
this.parentMenu = null;
this.parentItem = null;
this.ref = null;

}

function Item1(image, text, href, frame, length, spacing, target) {
this.image = image + ' alt="' + text + '" valign=top name="' + text + '"></td>';
this.text = text;
if (href==''){
this.href = "index_e.htm";
}else{
this.href = href;
}
this.frame = frame;

if(length > 1) {
  this.length = (length - 1) * heightL1 * 1.6;
} else {
  this.length = length * heightL1;  
}
AddMenuHeight(this.length);

this.spacing = spacing;
this.target = target;
this.ref = null;
}

function Item2(image, text, href, frame, length, spacing, target) {
this.image = image + ' alt="' + text + '" valign=top name="' + text + '"></td>';
this.text = text;
if (href==''){
this.href = "index_e.htm";
}else{
this.href = href;
}
this.frame = frame;

if(length > 2) {
  this.length = heightL1 * (1.6 + (length-2)*0.8);
} else if(length > 1) {
  this.length = heightL1 * 1.6;
} else {
  this.length = length * heightL1;  
}

this.spacing = spacing;
this.target = target;
this.ref = null;
}

function moveRoot()
{
 with(menu[0][0].ref) left = ((parseInt(left) < 100) ? 100 : 5);
}

function clickHandle(evt)
{
 if (isNS4xx) document.routeEvent(evt);
 hideAllBut(0);
}


