// Title: ODB Screen Select
// URL: http://www.onlinedb.com.au	
// Version: 1.0
// Date: 03-18-2006 (mm-dd-yyyy)
// Notes: Copyright Onlinedb Pty Ltd
// Visit official site for details.

// Remove the Comment to enable Debug
var appdebug = 0
 


var width = screen.width
var height = screen.height

var resopt = '600'
var	mainmenuwidth = 105
var	mainmenuheight = 14
var	submenuwidth = 105
var	submenuheight = 14
var subblockleft = 106


if (height >= 1200)
{ 	resopt='1200'
	mainmenuwidth = 211
	mainmenuheight = 28
	submenuwidth = 244
	submenuheight = 28
	subblockleft = 213
}
else
{	
	if (height >= 1024)
	{ 	resopt='1024'
		mainmenuwidth = 180
		mainmenuheight = 24
		submenuwidth = 180
		submenuheight = 24
		subblockleft = 182

	}
	else
	{
		if (height >= 864)
		{ 	resopt='864'
			mainmenuwidth = 151
			mainmenuheight = 20
			submenuwidth = 151
			submenuheight = 20
			subblockleft = 153

		}
		else
		{
			if (height >= 768)
			{ 	resopt='768'
				mainmenuwidth = 135
				mainmenuheight = 18
				submenuwidth = 135
				submenuheight = 18
				subblockleft = 136

			}
		}
	}
}

document.write('<link rel="stylesheet" href="menu_files/menu_'+resopt+'.css">')
document.write('<link rel="stylesheet" href="odb-pages/odbstyle_'+resopt+'.css">')
document.write('<link rel="stylesheet" href="odb-pages/odbstyle.css">')


//Write if Debug
if (appdebug == 1)
{
	document.write("You're set to "+width+ "X" +height+ " "+ resopt )
}

	function wrap (s_text, n_state) {
		return (this.TMi
			? '<table cellspacing="0" cellpadding="0" border="0" width="100%" height="20"><tr><td width="17">' + (n_state ? '<img src="img/lev1_arrow.gif" border="0">' : '&nbsp;') + '<td class="TM0i0">' + s_text + '</td></tr></table>'
			: '<table cellspacing="0" cellpadding="' + (n_state ? 3 : 2) +'" border="0" width="100%" height="20"><tr><td valign="top" background="img/lev0_bg' + (n_state ? 2 : 1) + '.gif" class="TM0i' + (n_state ? 1 : 0) + '">' + s_text + '</td></tr></table>'
		);
	}


