function zoomIn(mapName,bbox,orig_bbox,symbols)
	{
	setMode("zoomIn");
	setRequestTarget("map",mapName,bbox,symbols);
	}

function zoomOut(mapName,bbox,orig_bbox,symbols)
	{
	setMode("zoomOut");
	setRequestTarget("map",mapName,bbox,symbols);
	}

function reCenter(mapName,bbox,orig_bbox,symbols)
	{
	setMode("reCenter");
	setRequestTarget("map",mapName,bbox,orig_bbox,symbols);
	}

function panMap(direction)
	{
	setMode("panMap");
	parent.map.document.mapform.direction = direction;
	}

function unZoom(mapName,bbox,orig_bbox,symbols)
	{
		parent.contents.document.location = '../cf_template/venstre.cfm?mapName='+ mapName + '&bbox=518761.0,6585656.0,560059.0,6627118'  + '&orig_bbox=518761.0,6585656.0,560059.0,6627118';
		parent.toolbar.document.location = '../cf_template/meny.cfm?mapName='+ mapName + '&bbox=518761.0,6585656.0,560059.0,6627118' + '&orig_bbox=518761.0,6585656.0,560059.0,6627118' + '&symbols=' +symbols+ '&mode=ZoomIn';
		parent.map.document.location = '../cf_template/map.cfm?mapName='+ mapName + '&bbox=518761.0,6585656.0,560059.0,6627118'  + '&orig_bbox=518761.0,6585656.0,560059.0,6627118' + '&symbols=' +symbols;
	}

function identFeature(mapName,bbox)
	{
	setMode("identify");
	setRequestTarget("rapport2",mapName,bbox);
	}



function setMode(mode)
{
	parent.map.document.mapform.MODE.value = mode;
}

/*	setRequestTarget()
		Used to set the form target and action parameters
		in the map.cfm
		Parameters:
			frame - the target frame
*/
function setRequestTarget(frame,mapName,bbox,orig_bbox,symbols)
{
	// Recenter, ZoomIn, ZoomOut
	if ( frame == "map" )
	{
		parent.map.document.mapform.action = '../cf_template/map.cfm?mapName='+ mapName+ '&symbols=' +symbols;
		parent.map.document.mapform.bbox = bbox;
                parent.map.document.mapform.orig_bbox = orig_bbox;
		parent.map.document.mapform.target = "map";
	}
	// Select and Identify
	else
	{
		parent.map.document.mapform.action = '../cf_template/featureInfo.cfm?mapName='+ mapName +'&bbox='+ bbox +'&orig_bbox='+ orig_bbox;
		parent.map.document.mapform.target = "rapport2";
	}
}
