 // font switcher

function switchFont() {
	if (getActiveStyleSheet() == "largeFonts") {
		setActiveStyleSheet('default');
	} else {
		setActiveStyleSheet('largeFonts');
	}
}

// Index IT
function printSPC() {
	var contents = document.getElementById('spcContents').innerHTML;
	var win = window.open('','','status=yes, scrollbars=yes, resizable=yes, width=400,height=400');
	win.document.write("<html><head><title>SPC tulostus</title><link rel='stylesheet' href='/indox/nam/styles/spcprint.css' type='text/css'></head><body>"+contents+"</body></html>");
	win.document.close();
	win.print();
}
function searchSPC()
{
	document.location="/indox/nam/humspc.jsp?vaikuttavat"+gup("aine");
}

function gup( name ){  name = name.replace(/[\[]/,"\\\[").replace(/[\]]/,"\\\]").toLowerCase();  var regexS = "[\\?&]"+name+"=([^&#]*)";  var regex = new RegExp( regexS );  var results = regex.exec( window.location.href.toLowerCase() );  if( results == null )    return "";  else    return results[1];}

