function showWin (url) {
	win = window.open("/"+url+".php", "", "width=500,height=400;left=50,top=50,location=no,menubar=no,resizable=no,scrollbars=yes,toolbar=no");
}

function playTrack (id) {
	player = findFlash("sl_player");
	if (!player) {
		alert ("Your Browser doesn't support this feature.\nPlease use the controls on the main player.");
		exit();
	}
	player.SetVariable("sl_trackId",id);
	player.TCallFrame("/",2);
}

function textCounter(field, countfield, maxlimit) 
  {
  if (field.value.length > maxlimit) 
  field.value =field.value.substring(0, maxlimit); 
  else
  countfield.value = maxlimit - field.value.length;
  } 

function tellAFriend (artId) {
	win = window.open("/tellAFriend.php?id="+artId, "", "width=500,height=400;left=50,top=50,location=no,menubar=no,resizable=no,scrollbars=yes,toolbar=no");	
}

 function initialize() {
      if (GBrowserIsCompatible()) {
        var map = new GMap2(document.getElementById("map_canvas"));
        map.setCenter(new GLatLng(37.4419, -122.1419), 13);
      }
    }

function Sichtbar()
 {
var objekt = document.getElementById('unsichtbar');
var objekt2 = document.getElementById('unsichtbar2');
var objekt3 = document.getElementById('unsichtbar3');
  if (objekt.style.display === 'none') {objekt.style.display = '';
  objekt2.style.display = '';
  objekt3.style.display = '';}
  else {objekt.style.display = 'none';
  objekt2.style.display = 'none';
  objekt3.style.display = 'none';}
}

function findFlash (flash) {
   if (document.all) {
      if (document.all[flash]) {
        return document.all[flash];
      }
      if (window.opera) {
        var movie = eval(window.document + flash);
        if (movie.SetVariable) {
          return movie;
        }
      }
      return;
    }
    if(document.layers) {
      if(document.embeds) {
        var movie = document.embeds[flash];
        if (movie.SetVariable) {
          return movie;
        }
      }
      return;
    }
    if (!document.getElementById) {
      return;
    }
    var movie = document.getElementById(flash);
    if (movie.SetVariable) {
      return movie;
    }
    var movies = movie.getElementsByTagName('embed');
    if (!movies || !movies.length) {
      return;
    }
    movie = movies[0];
    if (movie.SetVariable) {
      return movie;
    }
    return;
  }

  function showGig (id) {
 	win = window.open('/showGig.php/'+id+'/',"Details","scrollbars=yes,width=410,height=410,left=100,top=100");
  }