function ConfirmDelete(question,url)
	{
 	var where_to= confirm(question);
 	if (where_to== true)
 		{
	   	window.location=url;
 		}
	}

function CheckFileForm()
	{
	var alertstr;
 	if (!document.updfileform.bigtext.value)
 		{ 		
 		alertstr = "Klickbar text saknas\n";
 		}
 	if (!document.updfileform.file.value)
 		{
 		alertstr += "Fil saknas\n";
 		}
 	if (alertstr)
 		{
		alert(alertstr); 	
 		return false;
 		}
 	return true;
	}

var WindowObjectReference = null;

function popUp(URL) {
	WindowObjectReference = window.open(URL, 'name', 'toolbar=1,scrollbars=1,location=0,statusbar=0,menubar=0,resizable=1,width=960,height=800,left = 560,top = 300');
	if (window.focus) {WindowObjectReference.focus();}
	}	


function ToggleHouseGraphics(arg)
	{
	if (arg == "turndiv")
		{
		animatedcollapse.show('turndiv');		
		animatedcollapse.hide('mainpicdiv');
		$("#turndivlink").addClass('selected');
		$("#mainpiclink").removeClass('selected');
		}
	else
		{
		animatedcollapse.show('mainpicdiv');		
		animatedcollapse.hide('turndiv');
		$("#turndivlink").removeClass('selected');
		$("#mainpiclink").addClass('selected');
		}
	}

function RedirectUrl(form)
	{
	//alert('test');
	//alert(document.showprice.redirecturl.value);
	var index = document.getElementById('redirecturl').selectedIndex;
	var url = document.getElementById('redirecturl').value;
	if (url)
		{
		window.location = url;
		}
	}
