function generateRandSeq()
  {
      var i, seq = "";
      for (i = 1; i <= 32; i = i + 1) {
          seq += randomChar("abcdefghijklmnopqrstuvwxyz1234567890");
      }
      return seq;
  }
  
function pulldown_menu()
{
	var url = document.Form1.artist.options[document.Form1.artist.selectedIndex].value
	window.location.href = url 
}

function randomInt(low, high) 
{ 
    return Math.floor(Math.random()*(high-low+1)) + low; 
}  

function randomChar(str) 
{  
    return str.charAt(randomInt(0, str.length-1)); 
}  

function readID() {
var id = GetCookie('id');
if (id == null || id == "no id") {
	if (location.search.length > 1) id = location.search.substring(1, location.search.length);
	else id = generateRandSeq();
	if (id != GetCookie('id')) SetCookie('id', id);
}


return id;

}

function getCookieVal (offset) {  
var endstr = document.cookie.indexOf (";", offset);  
if (endstr == -1)    
endstr = document.cookie.length;  
return unescape(document.cookie.substring(offset, endstr));
}

function GetCookie (name) {  
var arg = name + "=";  
var alen = arg.length;  
var clen = document.cookie.length;  
var i = 0;  
while (i < clen) {    
var j = i + alen;    
if (document.cookie.substring(i, j) == arg)      
return getCookieVal (j);    
i = document.cookie.indexOf(" ", i) + 1;    
if (i == 0) break;   
}  
return null;
}

function SetCookie (name, value) {  
var argv = SetCookie.arguments;  
var argc = SetCookie.arguments.length;  
document.cookie = name + "=" + escape (value);
}

