// JavaScript Document
<!--
var time = 3000;
var numofitems = 6;

//menu constructor
function menu(allitems,thisitem,startstate){ 
  callname= "gl"+thisitem;
  divname="subglobal"+thisitem;  
  this.numberofmenuitems = 6;
  this.caller = document.getElementById(callname);
  this.thediv = document.getElementById(divname);
  this.thediv.style.visibility = startstate;
}

//menu methods
function ehandler(event,theobj){
  for (var i=1; i<= theobj.numberofmenuitems; i++){
    var shutdiv =eval( "menuitem"+i+".thediv");
    shutdiv.style.visibility="hidden";
  }
  theobj.thediv.style.visibility="visible";
}
function createInput(){
new_input = '1)<input type="file" name="userfiles[]" value="" onchange="createInput()" size="30">2)<input type="text" name="kommentar[]" size="30"><br>'
eval('document.upload_form.insertAdjacentHTML("AfterBegin", new_input)');
}
				
function closesubnav(event){
  if ((event.clientY <48)||(event.clientY > 107)){
    for (var i=1; i<= numofitems; i++){
      var shutdiv =eval('menuitem'+i+'.thediv');
      shutdiv.style.visibility='hidden';
    }
  }
}
function popUp(URL,WIDTH,HEIGHT) {
var winlinks = (screen.width - WIDTH) / 2;
var winoben = (screen.height - HEIGHT) / 2;
day = new Date();
id = day.getTime();
eval("page" + id + " = window.open(URL, '" + id + "', 'toolbar=0,scrollbars=0,location=0,statusbar=0,menubar=0,resizable=0,width="+WIDTH+",height="+HEIGHT+",left = "+winlinks+",top = "+winoben+"');");
}
function FullScreenPopUp(URL) {
day = new Date();
id = day.getTime();
eval("page" + id + " = window.open(URL, '" + id + "', 'toolbar=0,scrollbars=1,location=0,statusbar=0,menubar=0,resizable=0,width="+screen.width+",height="+screen.height+",left=0,top=0');");
}
function change(listname)
{
	document.getElementById(listname).options[0].selected = true;
}
function clearFields()
{
	document.upload_form.newDir.value = "";
}
function addbookmark(section) 
{ 
bookmarkurl="http://www.fcallschwil.ch/index.php?section="+section+"#Content"
bookmarktitle="FC Allschwil "+section
if (document.all) 
	window.external.AddFavorite(bookmarkurl,bookmarktitle) 
} 
// -->