var menus = [];

// --- menu class ---
function menu (item_struct, pos, styles) {
	// browser check
	this.item_struct = item_struct;
	this.pos = pos;
	this.styles = styles;
	this.id = menus.length;
	this.items = [];
	this.children = [];
	
	this.add_item = menu_add_item;
	this.hide = menu_hide;
	
	this.onclick = menu_onclick;
	this.onmouseout = menu_onmouseout;
	this.onmouseover = menu_onmouseover;
	this.onmousedown = menu_onmousedown;
	
	var i;
	for (i = 0; i < this.item_struct.length; i++)
		new menu_item(i, this, this);
	for (i = 0; i < this.children.length; i++)
		this.children[i].visibility(true);
	menus[this.id] = this;
}
function menu_add_item (item) {
	var id = this.items.length;
	this.items[id] = item;
	return (id);
}
function menu_hide () {
	for (var i = 0; i < this.items.length; i++) {
		this.items[i].visibility(false);
		this.items[i].switch_style('onmouseout');
	}
}
function menu_onclick (id) {
	var item = this.items[id];
	return (item.fields[1] ? true : false);
}
function menu_onmouseout (id) {
	this.hide_timer = setTimeout('menus['+ this.id +'].hide();',
		this.pos['hide_delay'][this.active_item.depth]);
	if (this.active_item.id == id)
		this.active_item = null;
}
function menu_onmouseover (id) {
	this.active_item = this.items[id];
	clearTimeout(this.hide_timer);
	var curr_item, visib;
	for (var i = 0; i < this.items.length; i++) {
		curr_item = this.items[i];
		visib = (curr_item.arrpath.slice(0, curr_item.depth).join('_') ==
			this.active_item.arrpath.slice(0, curr_item.depth).join('_'));
		if (visib)
			curr_item.switch_style (
				curr_item == this.active_item ? 'onmouseover' : 'onmouseout');
		curr_item.visibility(visib);
	}
}
function menu_onmousedown (id) {
	this.items[id].switch_style('onmousedown');
}
// --- menu item Class ---
function menu_item (path, parent, container) {
	this.path = new String (path);
	this.parent = parent;
	this.container = container;
	this.arrpath = this.path.split('_');
	this.depth = this.arrpath.length - 1;
	// get pointer to item's data in the structure
	var struct_path = '', i;
	for (i = 0; i <= this.depth; i++)
		struct_path += '[' + (Number(this.arrpath[i]) + (i ? 2 : 0)) + ']';
	eval('this.fields = this.container.item_struct' + struct_path);
	if (!this.fields) return;
	
	// assign methods	
	this.get_x = mitem_get_x;
	this.get_y = mitem_get_y;
	// these methods may be different for different browsers (i.e. non DOM compatible)
	this.init = mitem_init;
	this.visibility = mitem_visibility;
	this.switch_style = mitem_switch_style;
	
	// register in the collections
	this.id = this.container.add_item(this);
	parent.children[parent.children.length] = this;
	
	// init recursively
	this.init();
	this.children = [];
	var child_count = this.fields.length - 2;
	for (i = 0; i < child_count; i++)
		new menu_item (this.path + '_' + i, this, this.container);
	this.switch_style('onmouseout');
}
function mitem_init() {
	document.write (
		'<a id="mi_' + this.container.id + '_'
			+ this.id +'" class="m' + this.container.id + 'l' + this.depth 
			+'o" href="' + this.fields[1] + '" style="position: absolute; top: '
			+ this.get_y() + 'px; left: '	+ this.get_x() + 'px; width: '
			+ this.container.pos['width'][this.depth] + 'px; height: '
			+ this.container.pos['height'][this.depth] + 'px; visibility: hidden;'
			+' background: black; color: white; z-index: ' + this.depth + ';" '
			+ 'onclick="return menus[' + this.container.id + '].onclick('
			+ this.id + ');" onmouseout="menus[' + this.container.id + '].onmouseout('
			+ this.id + ');" onmouseover="menus[' + this.container.id + '].onmouseover('
			+ this.id + ');" onmousedown="menus[' + this.container.id + '].onmousedown('
			+ this.id + ');"><div class="m'  + this.container.id + 'l' + this.depth + 'i">'
			+ this.fields[0] + "</div></a>\n"
		);
	this.element = document.getElementById('mi_' + this.container.id + '_' + this.id);
}
function mitem_visibility(make_visible) {
	if (make_visible != null) {
		if (this.visible == make_visible) return;
		this.visible = make_visible;
		if (make_visible)
			this.element.style.visibility = 'visible';
		else if (this.depth)
			this.element.style.visibility = 'hidden';
	}
	return (this.visible);
}
function mitem_get_x() {
	var value = 0;
	for (var i = 0; i <= this.depth; i++)
		value += this.container.pos['block_left'][i]
		+ this.arrpath[i] * this.container.pos['left'][i];
	return (value);
}
function mitem_get_y() {
	var value = 0;
	for (var i = 0; i <= this.depth; i++)
		value += this.container.pos['block_top'][i]
		+ this.arrpath[i] * this.container.pos['top'][i];
	return (value);
}
function mitem_switch_style(state) {
	if (this.state == state) return;
	this.state = state;
	var style = this.container.styles[state];
	for (var i = 0; i < style.length; i += 2)
		if (style[i] && style[i+1])
			eval('this.element.style.' + style[i] + "='" 
			+ style[i+1][this.depth] + "';");
}


var MENU_ITEMS = [
	['Basics', 'basics.html',
		['Focus', 'basics.html#focus'],
		['Types of Risk', 'basics.html',
			['Liquidity', 'basics.html#liquidity'],
			['Credit', 'basics.html#credit'],
			['Sovereign', 'basics.html#sovereign'],
			['Market', 'basics.html#market'],
			['Settlement', 'basics.html#settlement'],
			['Interest Rate', 'basics.html#interestrate'],
			['Foreign Exchange', 'basics.html#forex'],
			['Capital', 'basics.html#capital'],
			['Fraud', 'basics.html#fraud'],
			['Reputation', 'basics.html#reputation'],
			['Legal', 'basics.html#legal'],
			['Operations', 'basics.html#operations'],
			['Overhead', 'basics.html#overhead'],
			['Regulatory', 'basics.html#regulatory'],
			['Economic', 'basics.html#economic'],
			['Credit Rating Agency', 'basics.html#creditrating'],
		],
		['Analysis Basics', 'basicanal.html',
			['Accounting', 'basicanal.html#accounting'],
			['Cash Flow', 'basicanal.html#cashflow'],
			['Ratio Analysis', 'basicanal.html#ratios'],
			['Credit Scoring', 'basicanal.html#scoring'],
		],
		['U.S. Economy', 'useconomy.html',
			['Federal Deficit', 'useconomy.html#govdeficit'],
			['Trade Deficit', 'useconomy.html#tradedeficit'],
			['Social Security', 'useconomy.html#socialsecurity'],
			['Health Care', 'useconomy.html#healthcare'],
			['U.S. Indicators', 'useconomy.html#us'],
		],
		['Accounting Issues', 'accounting.html',
			['FASB', 'accounting.html#fasb'],
			['IAS', 'accounting.html#ias'],
			['Options Accounting', 'accounting.html#options'],
			['Pension Accounting', 'accounting.html#pensions'],
			['Sarbanes Oxley', 'accounting.html#sarbanes'],
			['Dutch Language', 'dutch.html'],
			['French Language', 'french.html'],
			['German Language', 'german.html'],
			['Italian Language', 'italian.html'],
			['Spanish Language', 'spanish.html'],
		],
		['Taxation', 'tax.html',
			['Corp. Tax Rates', 'tax.html#corprates'],
			['VAT Tax Rates', 'tax.html#vatrates'],
			['IRS Forms', 'tax.html#fedforms'],
			['State Forms', 'tax.html#stateforms'],
			['International', 'tax.html#international'],
			['U.S. Business', 'tax.html#usbusiness'],
			['U.S. Individual', 'tax.html#usindividual'],
		],
		['Credit Rating Agencies', 'ratings.html'],
		['Business Travel', 'travel.html',
			['Airports & Airlines', 'travel.html#usairports'],
			['Air Travel Guide', 'travel.html#airguide'],
			['Airline Luggage Guide', 'travel.html#allow'],
			['Airport Delay', 'travel.html#delay'],
			['Embassies', 'travel.html#embassy'],
			['Health & Safety', 'travel.html#health'],
			['Telecommunications', 'travel.html#telco'],
			['Travel Plan Resources', 'travel.html#planning'],
			['U.S. Passport Guide', 'travel.html#uspassport'],
			['Weather', 'travel.html#weather'],
			['New York Guide', 'ny.html'],
			['London Guide', 'london.html'],
			['Frankfurt Guide', 'frankfurt.html'],
			['Dubai Guide', 'dubai.html'],
			['Mumbai Guide', 'mumbai.html'],
			['Hong Kong Guide', 'hongkong.html'],
			['Shanghai Guide', 'shanghai.html'],
			['Tokyo Guide', 'tokyo.html'],
			['Cayman Islands Guide', 'cayman.html'],
		],
		['Computers', 'computers.html'],
		['After Hours', 'afterhours.html'],
	],
	['Analysis', null,
		['Bank', 'bank.html'],
		['Investment Bank', 'investbank.html'],
		['Finance Co.', 'finco.html'],
		['Credit Union', 'cuanal.html'],
		['Corporation', 'corp.html'],
		['Insurance', 'insurco.html'],
		['Project Finance', 'projfin.html'],
		['Taxicab Medallion', 'taxi.html'],
		['Sovereign', 'sovereign.html'],
		['Risk Analysis', 'riskmeasure.html',
			['Alpha (&#945;)', 'riskmeasure.html#alpha'],
			['Beta (&#223;)', 'riskmeasure.html#beta'],
			['VAR', 'riskmeasure.html#var'],
			['Delta (&#916;)', 'riskmeasure.html#delta'],
			['KMV', 'riskmeasure.html#kmv'],
			['Monte Carlo', 'riskmeasure.html#montecarlo'],
			['RAROC', 'riskmeasure.html#raroc'],
			['Sharpe Ratio', 'riskmeasure.html#sharpe'],
			['Standard Deviation', 'riskmeasure.html#sd'],
			['Theta (&#920;)', 'riskmeasure.html#theta'],
			['Vega', 'riskmeasure.html#vega'],
		],
		['Bankruptcy', 'bankruptcy.html',
			['Chapter 7', 'bankruptcy.html#chap7'],
			['Chapter 11', 'bankruptcy.html#chap11'],
			['Chapter 13', 'bankruptcy.html#chap13'],
			['Real Estate Foreclosure', 'bankruptcy.html#foreclose'],
		],
	],
	['Markets &#38; Finance', 'debt.html',
		['Market Regulation', 'secreg.html',
			['Banking', 'banklaw.html'],
			['Securities', 'secreg.html'],
			['Commodities', 'marketreg.html'],
			['Credit Unions', 'cureg.html'],
		],
		['Banking', 'banking.html',
			['International Banking', 'banking.html'],
			['BIS', 'banklaw.html#bis'],
			['Federal Reserve', 'banklaw.html#fed'],
			['Bank Regulation', 'banklaw.html'],
			['Deposit Insurance', 'banking.html#depins'],
			['FHLB System', 'banking.html#fhlb'],
			['Type &#38; Function', 'banking.html#type'],
			['Offshore Banking', 'banking.html#offshore'],
			['Islamic Banking', 'islamicbanking.html'],
			['Microfinance', 'micro.html'],
			['Farm Credit Banks', 'banking.html#ffcb'],
			['Bank Websites', 'banksites.html'],
		],
		['Debt', 'debt.html',
			['Basics', 'debt.html'],
			['Government', 'debt.html#gov'],
			['Supranational', 'debt.html#supra'],
			['Government Agency', 'debt.html#agency'],
			['GSE', 'debt.html#gse'],
			['State&#47;Municipal', 'debt.html#muni'],
			['Build America Bonds', 'debt.html#babs'],
			['Corporate', 'debt.html#corp'],
			['Asset-backed', 'debt.html#abs'],
			['Equity Linked Notes', 'debt.html#eltn'],
			['Index Linked Notes', 'debt.html#iln'],
			['Ratings', 'ratings.html'],
			['Syndicated Loan', 'debt.html#synloan'],
			['Regulation', 'secreg.html'],
		],
		['Money Market', 'moneymarket.html',
			['Fed Funds', 'moneymarket.html#fedfunds'],
			['Discount Window', 'moneymarket.html#diswin'],
			['EONIA', 'moneymarket.html#eonia'],
			['CDs', 'moneymarket.html#cd'],
			['Eurodollar / LIBOR', 'moneymarket.html#eurodollar'],
			['Prime Rate', 'moneymarket.html#primerate'],
			['REPO', 'repos.html'],
			['T-Bill', 'moneymarket.html#tbill'],
			['Bankers Acceptance', 'moneymarket.html#bankaccept'],
			['Commercial Paper', 'moneymarket.html#commpaper'],
			['Money Market Funds', 'moneymarket.html#funds'],
			['Auction Rate Securities', 'moneymarket.html#ars'],
		],
		['Consumer Credit', 'consumer.html',
			['Deposit Accounts', 'consumer.html#deposits'],
			['FDIC Insurance', 'consumer.html#fdic'],
			['Credit Cards', 'consumer.html#credcard'],
			['Debit Cards', 'consumer.html#debitcard'],
			['Annuity', 'consumer.html#annuity'],
			['Student Loans', 'consumer.html#student'],
			['FICO', 'consumer.html#fico'],
			['Credit Agencies', 'consumer.html#cras'],
			['Peer-To-Peer', 'consumer.html#p2p'],
		],
		['Credit Unions', 'creditunion.html',
			['Federal Credit Union', 'creditunion.html#fed'],
			['State Credit Union', 'creditunion.html#state'],
			['Corp. Credit Union', 'creditunion.html#corp'],
			['CUSO', 'creditunion.html#cuso'],
			['Credit Union Websites', 'cusites.html'],
		],
		['Equity', 'equity.html',
			['Broker', 'equity.html#broker'],
			['Market Regulation', 'secreg.html'],
			['Flash Trading', 'equity.html#highfreq'],
			['Specialist', 'equity.html#specialist'],
			['Equity Exchanges', 'equity.html#exchanges'],
			['Exchange Directory', 'equity.html#directory'],
			['Equity Indices', 'indices.html'],
			['Dark Pools', 'equity.html#darkpool'],
			['Preferred Securities', 'equity.html#prefsec'],
			['ETFs', 'equity.html#etf'],
			['Regulation', 'secreg.html'],
		],
		['Asset Securitization', 'assetsecure.html',
			['MBS', 'assetsecure.html#mbs'],
			['CMBS', 'assetsecure.html#cmbs'],
			['CMO', 'assetsecure.html#cmo'],
			['SMBS', 'assetsecure.html#smbs'],
			['REMIC', 'assetsecure.html#remic'],
			['RESI', 'assetsecure.html#resi'],
			['CBO', 'assetsecure.html#cbo'],
			['CLO', 'assetsecure.html#clo'],
			['CDO', 'assetsecure.html#cdo'],
			['FASIT', 'assetsecure.html#fasit'],
			['SPV', 'assetsecure.html#spv'],
			['SIV', 'assetsecure.html#siv'],
			['Credit Cards', 'assetsecure.html#creditcards'],
			['Auto Loans', 'assetsecure.html#auto'],
			['Student Loans', 'assetsecure.html#student'],
			['ABS Regulation', 'assetsecure.html#regulation'],
		],
		['Commodities', 'commarket.html',
			['Cash Prices', 'commarket.html#cash'],
			['Cattle', 'commarket.html#cattle'],
			['Cocoa', 'commarket.html#cocoa'],
			['Coffee', 'commarket.html#coffee'],
			['Copper', 'commarket.html#copper'],
			['Corn', 'commarket.html#corn'],
			['Cotton', 'commarket.html#cotton'],
			['FCOJ', 'commarket.html#fcoj'],
			['Gold', 'commarket.html#gold'],
			['Hogs', 'commarket.html#hogs'],
			['Lumber', 'commarket.html#lumber'],
			['Petroleum', 'commarket.html#petro'],
			['Platinum', 'commarket.html#platinum'],
			['Silver', 'commarket.html#silver'],
			['Soybeans', 'commarket.html#soybeans'],
			['Sugar', 'commarket.html#sugar'],
			['Wheat', 'commarket.html#wheat'],
		],
		['Agriculture', 'agriculture.html',
			['International', 'agriculture.html#international'],
			['United States', 'agriculture.html#us'],
			['Commodity Credit Corp.', 'agriculture.html#ccc'],
			['Farm Credit Banks', 'agriculture.html#ffcb'],
			['GM Crops', 'agriculture.html#gm'],
			['Conversion Table', 'agriculture.html#convert'],
			['Vertical Farming', 'agriculture.html#vertical'],
		],
		['Trading &#38; Clearing', 'clearing.html',
			['Trading Systems', 'clearing.html#trading'],
			['ACH', 'clearing.html#ach'],
			['ACT', 'clearing.html#act'],
			['ATS', 'clearing.html#ats'],
			['CDCC', 'clearing.html#cdcc'],
			['CHIPS', 'clearing.html#chips'],
			['DTC', 'clearing.html#dtc'],
			['DTCC', 'clearing.html#dtcc'],
			['ECN', 'clearing.html#ecn'],
			['EFT', 'clearing.html#eft'],
			['Fedwire', 'clearing.html#fedwire'],
			['OASYS', 'clearing.html#oasys'],
			['SWIFT', 'clearing.html#swift'],
		],
		['Currencies/FOREX', 'currencies.html',
			['Rates & News', 'currencies.html#news'],
			['Currency Market', 'currencies.html#market'],
			['Risk Analysis', 'currencies.html#forexrisks'],
			['Trading & Settlement', 'currencies.html#forextrade'],
			['Futures', 'currencies.html#futures'],
			['Abbreviations', 'currencies.html#abbrev'],
		],
		['Futures Market', 'futures.html'],
		['Derivatives', 'derivatives.html',
			['Futures', 'futures.html'],
			['Options', 'options.html'],
			['Swaps', 'swaps.html'],
			['Forwards', 'forwards.html'],
			['Exchanges', 'exchanges.html'],
			['Rates &#38; Indices', 'finmarket.html'],
		],
		['Credit Derivatives', 'creditderiv.html',
			['Credit Default Swaps', 'creditderiv.html#cds'],
			['Total Return Swaps', 'creditderiv.html#trs'],
			['Spread-Linked Swaps', 'creditderiv.html#sls'],
			['Credit Event Futures', 'creditderiv.html#cef'],
			['Default Notes', 'creditderiv.html#dn'],
			['Spread-Linked Notes', 'creditderiv.html#sln'],
			['Levered Notes', 'creditderiv.html#ln'],
			['Credit-Linked Notes', 'creditderiv.html#cln'],
			['Default Options', 'creditderiv.html#do'],
		],
		['Trade & Transport', 'trade.html',
			['Bulk Carriers', 'trade.html#bulk'],
			['Carriers', 'trade.html#carrier'],
			['Containers', 'trade.html#containers'],
			['LNG Carriers', 'trade.html#lngcarrier'],
			['Seaports Directory', 'trade.html#seaports'],
			['Rail Freight', 'trade.html#rail'],
			['Air Cargo', 'trade.html#air'],
			['GATT', 'trade.html#gatt'],
			['Hague-Visby Rules', 'trade.html#hvr'],
			['FTAA', 'trade.html#ftaa'],
			['NAFTA', 'trade.html#nafta'],
			['Mercusor', 'trade.html#mercusor'],
			['Warsaw Convention', 'trade.html#warsaw'],
		],
		['REPOs', 'repos.html'],
		['Insurance', 'insurance.html',
			['Life Insurance', 'insurance.html#life'],
			['Health Insurance', 'insurance.html#health'],
			['Property &#38; Casualty', 'insurance.html#prop'],
			['Automotive', 'insurance.html#auto'],
			['Reinsurance', 'insurance.html#reinsur'],
			['Captive', 'insurance.html#captive'],
			['Marine', 'insurance.html#marine'],
			['Terrorism', 'insurance.html#terrorism'],
			['Viatical', 'viatical.html'],
		],
		['Catastrophe Risk', 'catastrophe.html',
			['Cat Risk Options', 'catastrophe.html#catoption'],
			['Cat Bonds', 'catastrophe.html#catbond'],
			['Cat Risk Swaps', 'catastrophe.html#catswap'],
			['CRIF', 'catastrophe.html#crif'],
		],
		['Letter of Credit', 'loc.html'],
		['Money &#38; Payments', 'ecash.html',
			['Paper Checks', 'ecash.html#checks'],
			['Credit Cards', 'ecash.html#creditcard'],
			['ATM Networks', 'ecash.html#atm'],
			['Debit Cards', 'ecash.html#debitcard'],
			['Prepaid Cards', 'ecash.html#prepaid'],
		],
		['SBA Lending', 'sba.html'],
		['Leases', 'lease.html'],
		['Hedge Funds', 'hedge.html'],
		['Mutual Funds', 'mutual.html'],
		['401k  &#38; IRA', 'investor.html'],
		['Microfinance', 'micro.html'],
	],
	['Commodities', 'commarket.html',
		['Basics', 'commarket.html',
			['Prices', 'commarket.html'],
			['Futures', 'futures.html'],
			['Exchanges', 'exchanges.html'],
			['Market Regulation', 'marketreg.html'],
			['Weights &#38; Measure', 'agriculture.html#convert'],
			['Agriculture', 'agriculture.html'],
			['GM Crops', 'agriculture.html#gm'],
		],
		['Coal', 'coal.html',
			['Coal Categories', 'coal.html#type'],
			['Coal Mining', 'coal.html#mining'],
			['Coal Transportation', 'coal.html#transport'],
			['Coal Pricing', 'coal.html#pricing'],
			['U.S. Production', 'coal.html#usproduction'],
			['Environmental Issues', 'coal.html#environmental'],
			['Carbon Trading', 'carbon.html'],
		],
		['Cocoa', 'cocoa.html',
			['Cacao Cultivation', 'cocoa.html#cultivation'],
			['Producing Nations', 'cocoa.html#producers'],
			['Cocoa Processing', 'cocoa.html#processing'],
			['Chocolate Industry', 'cocoa.html#manufacturers'],
		],
		['Coffee', 'coffee.html',
			['Coffee Cultivation', 'coffee.html#class'],
			['Producing Nations', 'coffee.html#producers'],
			['Coffee Futures', 'coffee.html#futures'],
			['Coffee Roasting', 'coffee.html#roasting'],
			['Coffee Companies', 'coffee.html#companies'],
			['Fair Trade Coffee', 'coffee.html#fairtrade'],
		],
		['Corn', 'corn.html',
			['Corn Production', 'corn.html#usproduction'],
			['Corn Consumption', 'corn.html#usconsumption'],
			['Crop Measurement', 'corn.html#conversion'],
			['Corn Futures', 'corn.html#futures'],
			['Ethanol', 'corn.html#ethanol'],
			['Corn Syrup', 'corn.html#hfcs'],
		],
		['Cotton', 'cotton.html',
			['Cotton Cultivation', 'cotton.html#cultivation'],
			['Cotton Classification', 'cotton.html#classification'],
			['Cotton Ginning', 'cotton.html#ginning'],
			['Producing Nations', 'cotton.html#producers'],
			['Supply & Demand', 'cotton.html#fundamentals'],
			['Cotlook A Index', 'cotton.html#cotlook'],
			['Cotton Futures', 'cotton.html#futures'],
		],
		['Dairy', 'dairy.html',
			['U.S. Production', 'dairy.html#usproduction'],
			['Raw Milk Processors', 'dairy.html#processors'],
			['Dairy Products', 'dairy.html#products'],
			['Health Issues', 'dairy.html#health'],
			['DEIP', 'dairy.html#deip'],
			['MILC', 'dairy.html#milc'],
		],
		['Diamonds', 'diamond.html',
			['Carat', 'diamond.html#carat'],
			['Clarity', 'diamond.html#clarity'],
			['Color', 'diamond.html#color'],
			['Cut', 'diamond.html#cut'],
		],
		['Electricity', 'electric.html',
			['Power Generation', 'electric.html'],
			['Power Plant Design', 'electric.html#design'],
			['Power Plant Fuels', 'electric.html#fuels'],
			['Transmission', 'electric.html#trans'],
			['Distribution', 'electric.html#dist'],
			['Wholesale Market', 'electric.html#wholesale'],
			['ISO / RTO', 'electric.html#iso'],
			['Power Marketers', 'electric.html#marketers'],
			['Power Exchanges', 'electric.html#exchanges'],
			['Futures Market', 'electric.html#futures'],
			['Market Regulation', 'electric.html#reg'],
			['Wind Power', 'wind.html'],
			['Solar Power', 'solar.html'],
			['Nuclear Power', 'electric.html#nuclear'],
			['Environmental Issues', 'electric.html#environmental'],
		],
		['Ethanol & Biofuel', 'ethanol.html',
			['Ethanol Production', 'ethanol.html#production'],
			['Ethanol Refining', 'ethanol.html#refining'],
			['U.S. Production', 'ethanol.html#usproduction'],
			['U.S. Consumption', 'ethanol.html#usconsumption'],
			['Brazil Production', 'ethanol.html#brazilproduction'],
			['Ethanol Producers', 'ethanol.html#producers'],
			['Ethanol Futures Market', 'ethanol.html#futures'],
			['Biofuels', 'ethanol.html#biofuels'],
			['Biodiesel', 'ethanol.html#biodiesel'],
		],
		['FCOJ', 'fcoj.html'],
		['Gold', 'gold.html',
			['Gold Mining', 'gold.html#mining'],
			['Gold Refining', 'gold.html#refining'],
			['Gold Mining Cos.', 'gold.html#companies'],
			['London Fixing', 'gold.html#londonfixing'],
			['Gold Fineness', 'gold.html#fineness'],
			['Weight Conversion', 'gold.html#conversion'],
			['Gold Loan', 'gold.html#goldloan'],
		],
		['Livestock', 'livestock.html',
			['Beef', 'livestock.html#beef'],
			['Beef Cuts', 'livestock.html#beefcuts'],
			['Pork', 'livestock.html#pork'],
			['Poultry', 'livestock.html#poultry'],
		],
		['Lumber', 'lumber.html',
			['Futures Contract', 'lumber.html#futures'],
			['Grade Stamping', 'lumber.html#stamp'],
			['Environmental Issues', 'lumber.html#environment'],
			['Lumber Industry', 'lumber.html#industry'],
			['SLA 2006', 'lumber.html#sla'],
			['Stumpage Fee', 'lumber.html#stumpage'],
			['Timber Cruise Report', 'lumber.html#cruise'],
		],
		['Natural Gas', 'natgas.html',
			['Gas Exploration', 'natgas.html#explore'],
			['Producing Nations', 'natgas.html#producers'],
			['Consumers', 'natgas.html#consumers'],
			['Gas Pipelines', 'natgas.html#trans'],
			['Natural Gas Price', 'natgas.html#price'],
			['LNG Market', 'natgas.html#lng'],
			['Environmental Issues', 'natgas.html#environment'],
			['Gas/Oil Comparison', 'natgas.html#compare'],
		],
		['Petroleum', 'petro.html',
			['Consumers', 'petro.html#consumers'],
			['Pricing', 'petro.html#pricing'],
			['Producers', 'petro.html#producers'],
			['Crude Oil', 'petro.html#crude'],
			['NYMEX Futures', 'petro.html#nymex'],
			['Refined Products', 'petro.html#refine'],
			['Gasoline', 'petro.html#gasoline'],
			['Diesel', 'petro.html#diesel'],
			['Oil Tar Sands', 'petro.html#tarsands'],
			['Carbon Trading', 'carbon.html'],
			['Research Sources', 'petro.html#resources'],
		],
		['Rice', 'rice.html',
			['Rice Cultivation', 'rice.html#cultivation'],
			['Rice Classification', 'rice.html#classification'],
			['Producing Nations', 'rice.html#producers'],
			['U.S. Production', 'rice.html#usproduction'],
			['Rice Futures Market', 'rice.html#futures'],
		],
		['Soybeans', 'soybean.html'],
		['Sugar', 'sugar.html',
			['Sugar Cultivation', 'sugar.html#cultivation'],
			['Sugarcane', 'sugar.html#sugarcane'],
			['Sugar Beets', 'sugar.html#beetsugar'],
			['Sugar Futures', 'sugar.html#futures'],
			['U.S. Production', 'sugar.html#usprod'],
			['Brazil Production', 'sugar.html#brazilprod'],
			['India Production', 'sugar.html#indiaprod'],
			['Molasses', 'sugar.html#molasses'],
		],
		['Wheat', 'wheat.html'],
		['Weather', 'weather.html',
		 	['Weather Indicators', 'weather.html#indicators'],
		 	['Temp. Conversion', 'weather.html#convert'],
		 	['Hurricanes', 'weather.html#hurricane'],
		 	['Weather Risk', 'weather.html#risk'],
		]
	],
	['Real Estate', 'commercial.html',
		['Residential', 'residential.html',
			['Primary Market', 'residential.html#primary'],
			['Mortgage Calculator', 'residential.html#mtgcalc'],
			['APR Calculator', 'residential.html#aprcalc'],
			['FHA Loans', 'residential.html#fha'],
			['PMI', 'residential.html#pmi'],
			['Coop Unit', 'residential.html#coop'],
			['Regulation Z', 'residential.html#regz'],
			['Reverse Mortgage', 'residential.html#revmtg'],
			['Secondary Market', 'residential.html#secondary'],
			['Underwriting', 'residential.html#underwrite'],
			['Appraisal', 'residential.html#appraisal'],
			['HP-12C Calculator', 'residential.html#payment'],
		],
		['Commercial', 'commercial.html',
			['Cap Rate', 'commercial.html#caprate'],
			['Construction Loan', 'commercial.html#constloan'],
			['Estoppel', 'commercial.html#estoppel'],
			['Ground Lease', 'commercial.html#groundlease'],
			['Lease Analysis', 'commercial.html#lease'],
			['Property Analysis', 'commercial.html#propanal'],
			['Hotel Property Analysis', 'commercial.html#hotel'],
			['Commercial Appraisal', 'commercial.html#appraisal'],
			['Cost Approach', 'commercial.html#cost'],
			['Sales Comp Approach', 'commercial.html#salescomp'],
			['Income Approach', 'commercial.html#income'],
			['Gross Income Multiplier', 'commercial.html#gim'],
			['1031 Exchange', 'commercial.html#1031'],
			['NPV / HP-12C', 'commercial.html#npv'],
			['Discounted Cash Flow', 'commercial.html#dcf'],
			['U.S. Tax Treatment', 'commercial.html#taxation'],
			['REIT Market', 'commercial.html#reit'],
			['Commercial Foreclosure', 'commercial.html#foreclose'],
		],
	],
	['Links', 'links.html',
		['Professional Services', 'services.html'],
		['Banking', 'links.html#banking',
			['FDIC', 'links.html#fdic'],
			['Federal Reserve', 'links.html#fed'],
			['Banking Associations', 'links.html#bankers'],
			['Bank Websites', 'banksites.html'],
			['Deposit Insurance', 'links.html#depinsur'],
			['Central Banks', 'links.html#cenbank'],
			['Islamic Banks', 'islamicbanking.html#banks'],
			['Farm Credit Banks', 'farmbanksites.html'],
		],
		['Credit Unions', 'cusites.html'],
		['Mortgage Market', 'links.html#mortgage'],
		['Sovereign Govt.', 'links.html#sovereign'],
		['Supranational', 'links.html#supranational'],
		['Commodities', 'commarket.html',
			['Coal', 'coal.html#resources'],
			['Cocoa', 'cocoa.html#resources'],
			['Coffee', 'coffee.html#resources'],
			['Corn', 'corn.html#resources'],
			['Cotton', 'cotton.html#resources'],
			['Diamonds', 'diamond.html#resources'],
			['Electricity', 'electric.html#resources'],
			['FCOJ', 'fcoj.html#resources'],
			['Gold', 'gold.html#resources'],
			['Live Quote', 'links.html#commexchange'],
			['Livestock', 'livestock.html#resources'],
			['Lumber', 'lumber.html#resources'],
			['Metals', 'links.html#metals'],
			['Petroleum &#38; Gas', 'links.html#petroleum'],
			['Silver', 'links.html#silver'],
			['Soybeans', 'soybean.html#resources'],
			['Sugar', 'sugar.html#resources'],
			['Vegetable Oils', 'links.html#oils'],
			['Weather', 'links.html#weather'],
			['Wheat', 'links.html#wheat'],
		],
		['Clearing & Settlement', 'clearing.html#resources'],
		['Debt Exchanges', 'links.html#fixed'],
		['FOREX Rates', 'currencies.html'],
		['Commodity Exch.', 'exchanges.html'],
		['Equity Exchanges', 'equity.html#directory'],
		['Fixed Income Exch.', 'links.html#fixed'],
		['Futures Exchanges', 'exchanges.html'],
		['Options Exchanges', 'exchanges.html'],
		['Regulatory', 'links.html#regulate',
			['State Securities', 'links.html#statesecreg'],
			['State Bank Depts.', 'links.html#statebankreg'],
			['State Insurance Depts.', 'links.html#stateinsurereg'],
			['Canada Securities', 'links.html#canadasecreg'],
			['International Securities', 'links.html#Internationalreg'],
		],
		['Taxation', 'tax.html#resources'],
		['Legal', 'links.html#legal'],
		['Professional Assoc.', 'links.html#pro'],
		['Research Resources', 'links.html#research'],
		['Publications/Media', 'links.html#publications'],
		['International Trade', 'links.html#trade',
			['Export Credit Agency', 'links.html#credagency'],
			['Export Insurance', 'links.html#tradeins'],
		],
		['Offshore Finance', 'links.html#offshore'],
		['Travel Assistance', 'travel.html'],
	],
	['Companies Directory', 'services.html',
		['Applications', 'services.html#apps'],
		['Banking', 'services.html#bank'],
		['Barter Exchange', 'services.html#barter'],
		['Capital Markets Data', 'services.html#markets'],
		['Clearing Services', 'services.html#clearing'],
		['Consultants', 'services.html#consult'],
		['Credit Unions', 'services.html#cu'],
		['Electricity Markets', 'services.html#electric'],
		['Employment Services', 'services.html#employment'],
		['Energy Industry', 'services.html#energy'],
		['Exchanges', 'services.html#exchanges'],
		['Exposition/Trade Show', 'services.html#convention'],
		['Forex Trading', 'services.html#forex'],
		['International Trade', 'services.html#trade'],
		['Loan Audit', 'services.html#loanaudit'],
		['Natural Gas', 'services.html#natgas'],
		['Petroleum', 'services.html#petroleum'],
		['Publications', 'services.html#pub'],
		['Real Estate', 'services.html#realestate'],
		['Solar Power', 'services.html#solar'],
		['Trading Platform', 'services.html#platform'],
		['Travel Services', 'services.html#travel'],
		['Wind Power', 'services.html#wind'],
	],
	
];


var MENU_POS1 = new Array();
	// item sizes for different levels of menu
	MENU_POS1['height'] = [20, 20, 20];
	MENU_POS1['width'] = [125, 125, 125];
	// menu block offset from the origin:
	//	for root level origin is upper left corner of the page
	//	for other levels origin is upper left corner of parent item
	MENU_POS1['block_top'] = [60, 20, 0];
	MENU_POS1['block_left'] = [3, 0, 125];
	// offsets between items of the same level
	MENU_POS1['top'] = [0, 20, 20];
	MENU_POS1['left'] = [125, 0, 0];
	// time in milliseconds before menu is hidden after cursor has gone out
	// of any items
	MENU_POS1['hide_delay'] = [200, 200, 200];
	
/* --- dynamic menu styles ---
note: you can add as many style properties as you wish but be not all browsers
are able to render them correctly. The only relatively safe properties are
'color' and 'background'.
*/
var MENU_STYLES1 = new Array();
	// default item state when it is visible but doesn't have mouse over
	MENU_STYLES1['onmouseout'] = [
		'color', ['#ffffff', '#ffffff', '#ffffff'], 
		'background', ['#000080', '#000080', '#000080'],
		'fontWeight', ['normal', 'normal', 'normal'],
		'textDecoration', ['none', 'none', 'none'],
	];
	// state when item has mouse over it
	MENU_STYLES1['onmouseover'] = [
		'color', ['#000080', '#000080', '#000080'], 
		'background', ['#31b5d6', '#31b5d6', '#31b5d6'],
		'fontWeight', ['normal', 'normal', 'normal'],
		'textDecoration', ['none', 'none', 'none'],
	];
	// state when mouse button has been pressed on the item
	MENU_STYLES1['onmousedown'] = [
		'color', ['#ffffff', '#ffffff', '#ffffff'], 
		'background', ['#31b5d6', '#31b5d6', '#31b5d6'],
		'fontWeight', ['normal', 'normal', 'normal'],
		'textDecoration', ['none', 'none', 'none'],
	];


// create as many menus as you wish
	// each menu gets three parameters (see demo files)
	// 1. items structure
	// 2. geometry structure
	// 3. dynamic styles structure
	new menu (MENU_ITEMS, MENU_POS1, MENU_STYLES1);
	// also take a look at stylesheets loaded in header in order to set static styles


