function tlf(n) {
  window.open('http://www.gulesider.no/gsi/numberSearch.do?drill=&spraak=1&tel='+n)
}

function tlf2kart(n)
{
  window.open('http://kart.gulesider.no/kart/map.c?persons='+n)
}

function update_errorCol(id)
{
  var j=0;

//  alert(document.getElementById("IDC-"+id.toString()).checked);

  if (document.getElementById("IDC-"+id.toString()).checked) j+=1;
  if (document.getElementById("IDM-"+id.toString()).checked) j+=1;
  if (document.getElementById("IDF-"+id.toString()).checked) j+=1;
  if (document.getElementById("IDA-"+id.toString()).checked) j+=1;
  
  if (j==0) { document.images['img' + id.toString()].src="/gimages/error.GIF";}
  if (j==1) { document.images['img' + id.toString()].src="/gimages/OK.GIF";}
  if (j>1)  { document.images['img' + id.toString()].src="/gimages/warning.GIF";}
}
function test1() {
  document.messageForm.msgcounter.value = 40;
}

function openFullScreenFotoUrl(url,URLparam)
{
   window.open('http://'+url+'/include/slide.asp?' + URLparam, '', 'fullscreen=yes, width="100%", height="100%",statusbar=no, menubar=no, toolbar=no, scrollbar=no,resizable=no');
}




function openFullScreenFoto(URLparam)
{
   window.open('/include/slide.asp?' + URLparam, '', 'fullscreen=yes, width="100%", height="100%",statusbar=no, menubar=no, toolbar=no, scrollbar=no,resizable=no');
}
function fullScreenFotoSlideShowUrl(url,slideShowID){openFullScreenFotoUrl(url,'pageID=SlideShow&slideShowID=' + slideShowID);}
function fullScreenFotocsIDUrl(url,ArrangementID,csID){if(ArrangementID==0) {openFullScreenFotoUrl(url,'pageID=Random');} else {if (ArrangementID<0){fullScreenFotoSlideShowUrl(url,0-ArrangementID);} else { openFullScreenFotoUrl(url,'pageID=Arrangement&ArrangementID=' + ArrangementID +'&csID='+csID);}}}
function fullScreenFotoUrl(url,ArrangementID){fullScreenFotocsIDUrl(url,ArrangementID,0);}


function fullScreenFotoMember(memberID){openFullScreenFoto('pageID=Member&memberID=' + memberID);}
function fullScreenFotocsID(ArrangementID,csID){if(ArrangementID==0) {openFullScreenFoto('pageID=Random');} else {if (ArrangementID<0){fullScreenFotoSlideShow(0-ArrangementID);} else { openFullScreenFoto('pageID=Arrangement&ArrangementID=' + ArrangementID +'&csID='+csID);}}}
function fullScreenFoto(ArrangementID){fullScreenFotocsID(ArrangementID,0);}
function fullScreenFotoSlideShow(slideShowID){openFullScreenFoto('pageID=SlideShow&slideShowID=' + slideShowID);}
function fullScreenFotoFotoIDTitle(photoID,Title){openFullScreenFoto('pageID=photoID&photoID=' + photoID+'&Title='+Title);}
function fullScreenFotoFotoID(photoID){fullScreenFotoFotoIDTitle(photoID,'');}
function fullScreenFotoFotoID2FotoIDTitle(fromPhotoID,toPhotoID,Title){openFullScreenFoto('pageID=photoID2photoID&fromPhotoID=' + fromPhotoID+'&toPhotoID='+toPhotoID+'&Title='+Title);}
function fullScreenFotoFotoID2FotoID(fromPhotoID,toPhotoID){fullScreenFotoFotoID2FotoIDTitle(fromPhotoID,toPhotoID,'');}
function fullScreenFotoDate2DateTitle(fromDate,toDate,Title){openFullScreenFoto('pageID=date2date&fromDate=' + fromDate+'&toDate='+toDate+'&Title='+Title);}
function fullScreenFotoDate2Date(fromDate,toDate){fullScreenFotoDate2DateTitle(fromDate,toDate,'');}
function fullScreenFotoEventAndPhotographer(ArrangementID,CreatedBy){openFullScreenFoto('pageID=ArrangementAndCreatedBy&ArrangementID=' + ArrangementID+'&CreatedBy='+CreatedBy);}
function fullScreenFotoYear(year){openFullScreenFoto('pageID=Year&Year=' + year);}


function deletePicture(id)
{
  if(confirm('Slett bilde ' + id ))
  {
    window.location='/Default.asp?PageID=EditPhoto&GB=1&noHtml=1&Action=DeletePictureOK&Foto='+id;
  }
}