function FIND(item) {
	if( window.mmIsOpera ) return(document.getElementById(item));
	if (document.all) return(document.all[item]);
	if (document.getElementById) return(document.getElementById(item));
	return(false);
}

function addClass(target, theClass) {
	if (!target.className) 
		target.className = theClass;
	else 
		if (target.className.indexOf(theClass) == -1) target.className += ' ' + theClass;
}

function removeClass(target, theClass) {
	var pattern = new RegExp("(^| )" + theClass + "( |$)");
	target.className = target.className.replace(pattern, "$1");
	target.className = target.className.replace(/ $/, "");
}

function showtab(n) {
	for (i=1; i<=3; i++) {
		tab = FIND('tab_'+i);
		tabbox = FIND('tabbox_'+i);
		if (i==n) {
			if (tab != null) addClass(tab, 'active');
			if (tabbox != null) tabbox.style.display = 'block';
		} else {
			if (tab != null) removeClass(tab, 'active');
			if (tabbox != null) tabbox.style.display = 'none';
		}
	}
}


function OnLoadSetDefaultFocus(objname)
{
    if (obj = FIND('subm')) obj.style.display='none';
} 

window.onload = OnLoadSetDefaultFocus;
