function NavOver(thecell)
{
    thecell.background = "/images/nav_but_over.gif";
    thecell.style.color = "#FFFFFF";
    thecell.style.cursor = "pointer";
}

function NavOut(thecell)
{
    thecell.background = "/images/nav_but_up.gif";
    thecell.style.color = "#330066";
    thecell.style.cursor = "auto";
}

function ButOver(but)
	{
	but.style.background = "#663399";
	but.style.color = "#FFCCFF";
	//but.style.cursor = "pointer";
	}

function ButOut(but)
	{
	but.style.background = "#FFCCFF";
	but.style.color = "#663399";
	}

function C_Over(thecell)
{
    thecell.style.cursor = "pointer";
}

function C_Out(thecell)
{
    thecell.style.cursor = "auto";
}

function NavLink(page)
{
	parent.MAIN.location = page;
}

var HeightsImperialText = "4' 6\"~4' 7\"~4' 8\"~4' 9\"~4' 10\"~4' 11\"~5' 0\"~5' 1\"~5' 2\"~5' 3\"~5' 4\"~5' 5\"~5' 6\"~5' 7\"~5' 8\"~5' 9\"~5' 10\"~5' 11\"~6' 0\"~6' 1\"~6' 2\"~6' 3\"~6' 4\"~6' 5\"~6' 6\"~6' 7\"~6' 8\"~6' 9\"~6' 10\"~6' 11\"~7' 0\"~7' 1\"";
var HeightsImperialValues = "1.37~1.40~1.42~1.45~1.47~1.50~1.52~1.55~1.57~1.60~1.63~1.65~1.68~1.70~1.73~1.75~1.78~1.80~1.83~1.85~1.88~1.91~1.93~1.96~1.98~2.01~2.03~2.06~2.08~2.11~2.13~2.16";
var HeightsMetricValues = "1.37~1.38~1.39~1.40~1.41~1.42~1.43~1.44~1.45~1.46~1.47~1.48~1.49~1.50~1.51~1.52~1.53~1.54~1.55~1.56~1.57~1.58~1.59~1.60~1.61~1.62~1.63~1.64~1.65~1.66~1.67~1.68~1.69~1.70~1.71~1.72~1.73~1.74~1.75~1.76~1.77~1.78~1.79~1.80~1.81~1.82~1.83~1.84~1.85~1.86~1.87~1.88~1.89~1.90~1.91~1.92~1.93~1.94~1.95~1.96~1.97~1.98~1.99~2.00~2.01~2.02~2.03~2.04~2.05~2.06~2.07~2.08~2.09~2.10~2.11~2.12~2.13~2.14~2.15~2.16";
var RunFlag = 0;

function ToggleHeight(Control) 
{
var Metric = Control.options[1].text.indexOf("'")==-1 ? 1 : 0;
var Value = Control.options[Control.selectedIndex].value;
var Temp;
if (RunFlag == 0)
	{
	Value = StartHight;
	RunFlag = 1;
	}
if(Metric) 
	{
	var Temp = parseFloat(Value);
	Temp = (Temp*100)/2.54;
	Temp = Math.round(Temp);
	Temp = (Temp*2.54);
	Temp = Math.round(Temp);
	Temp = Temp/100;
	Value = Temp.toString();
	if(Value.length==3) Value += "0";
	Repopulate(Control,HeightsImperialText,HeightsImperialValues,TopText);
	}
else
	{
	Repopulate(Control,HeightsMetricValues,HeightsMetricValues,TopText);
	}
for(i=1; i<Control.options.length; i++)
	{
	if(parseFloat(Control.options[i].value) == parseFloat(Value))
		{
		Control.selectedIndex = i;
		break;
		}
	}
}

function Repopulate(Control,ItemText,Values,Default) 
{
if(Default=="undefined") Default = "";
var aValues = Values.split("~");
var aText = ItemText.split("~");
while (Control.options.length > 0) 
	{
	Control[0] = null;
	}
if(Default.length) Control[0] = new Option(Default,"0");
if(Values.length > 0) 
	{
	for(i=0; i<aValues.length; i++) 
		{
		Control[Control.length] = new Option(aText[i],aValues[i]);
		}
	}
Control.selectedIndex = 0;
}

function MM_openBrWindow(theURL,winName,features) { //v2.0
  window.open(theURL,winName,features);
}

function show_help(help_id)	{
	//MM_openBrWindow('/help_popup.php','help','scrollbars=no,resizable=yes,width=550,height=500')
	MM_openBrWindow('/help_and_support.php?id='+help_id,'help','scrollbars=yes,status=no,resizable=yes,width=470,height=300');
}
//function setStatusBar() { window.status = "www.singlemuslim.co.uk - The UK's leading introductions agency for single Muslims"; }
//window.setInterval("setStatusBar()",100);

function addbookmark(bookmarkurl,bookmarktitle){
	if (document.all){
		window.external.AddFavorite(bookmarkurl,bookmarktitle);
	} else {
		alert('Sorry, only Internet Explorer users can use this function.\n\nPlease user you browser\'s bookmarking facility.');
	}
}