function OpenWin(newwin, width, height) {
	w = width, h = height;
	windowheight = ((screen.height / 2) - (h / 2));
	windowwidth = ((screen.width / 2) - (w / 2));
	windowparams = "height=" + h +",width=" + w + ",scrollbars=0,top=" + windowheight + ",left=" + windowwidth
	window.open(newwin, "1", windowparams);
}

function OpenRegWin(newwin){
	window.open(newwin);
}

function call_fc_flash(arg1, arg2) {
	if(typeof(fc_flash) == "function"){
		fc_flash(arg1, arg2);
	}
}
function debug(message) {
	alert(message);
}

function setWindow () {
	/*
	window.resizeTo(screen.width,screen.height);
	*/
}

function MM_openBrWindow(theURL,winName,features) {
	window.open(theURL,winName,features);
}

function jumpMenu(targ,selObj,restore){
	startopen = window.open("","","");
	eval("startopen.location='"+selObj.options[selObj.selectedIndex].value+"'");
	if (restore) selObj.selectedIndex=0;
}
function inner_jumpMenu(targ,selObj,restore){
  eval(targ+".location='"+selObj.options[selObj.selectedIndex].value+"'");
  if (restore) selObj.selectedIndex=0;
}

function OpenNewsletter(params) {
	window.open("http://www.ktmnewsletter.com", "_blank");
}

function spacer(newH){
document.getElementById("spacergif").style.height = newH;
}
function spacer_new(newH){  
    newH = $('content').getHeight()
    newH = newH+132;
    $('spacergif').style.height = newH;
}

// Google -----------------------------------------------------------------------------------------------------------
var gMarker = [];
var gWindows = [];

function setMarkers(map, markers) {
	markers.each(
		function(item) {

              var image = new google.maps.MarkerImage('/fileadmin/inc/ds/flag.png', 
                  new google.maps.Size(35, 32), 
                  new google.maps.Point(0,0), 
                  new google.maps.Point(5, 30)); 
			
			var infoWindow = new google.maps.InfoWindow({
				content : item.content,
				zIndex : 59
			});
			gWindows.push(infoWindow);
			var marker = new google.maps.Marker({
				map:map,
				position:item.position,
				title:item.title,
				icon:image
			});
			marker.setVisible(true);
			gMarker.push(marker);
			google.maps.event.addListener(marker, 'click', function() {
				gWindows.each(function(item) {
					item.close();
				});
				infoWindow.open(map, marker);
			});
		}
	);
}

function showDisclaimer(){
    $('blacklayer').style.display = '';
    $('disclaimer').style.display = '';
    $('disclaimer').innerHTML = $('disclaimerTxt').innerHTML;
}
function hideDisclaimer(){
    $('blacklayer').style.display = 'none';
    $('disclaimer').style.display = 'none';
}
