function openhtms(bestand,breed,hoog) {
var xxwin,wd,hg;
if (window.screen) {
 wd=Math.round((window.screen.width-breed)/2);
 hg=Math.round((window.screen.height-hoog)/2);
 } else {
 wd=100;hg=100;
 }
xxwin=window.open(bestand,'openhtms','width='+breed+',height='+hoog+',left='+wd+',top='+hg+',dependent=yes,resizable=0,toolbar=0,scrollbars=1');
if (window.screen) xxwin.focus();
}

function openwindow(pic) {
var xxwin,wd,hg;
var breed=636;
var hoog=520;
if (window.screen) {
 wd=Math.round((window.screen.width-breed)/2);
 hg=Math.round((window.screen.height-hoog)/2);
 } else {
 wd=100;hg=100;
 }
picwin=window.open("images/showpic.htm?pic="+pic,'picwin','width='+breed+',height='+hoog+',left='+wd+',top='+hg+',dependent=yes,resizable=0,toolbar=0,scrollbars=1');
if (window.screen) picwin.focus();
}

function showpic(pic) {
var xxwin,wd,hg;
var breed=636;
var hoog=520;
if (window.screen) {
 wd=Math.round((window.screen.width-breed)/2);
 hg=Math.round((window.screen.height-hoog)/2);
 } else {
 wd=100;hg=100;
 }
pcwin=window.open("showpic.html?pic="+pic,'picwin','width='+breed+',height='+hoog+',left='+wd+',top='+hg+',dependent=yes,resizable=0,toolbar=0,scrollbars=1');
if (window.screen) pcwin.focus();
}

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; 
//alert(document.cookie);
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; 
var expires = (argc > 2) ? argv[2] : null; 
var path = (argc > 3) ? argv[3] : null; 
var domain = (argc > 4) ? argv[4] : null; 
var secure = (argc > 5) ? argv[5] : false; 
document.cookie = name + "=" + escape (value) + 
((expires == null) ? "" : ("; expires=" + expires)) + 
((path == null) ? "" : ("; path=" + path)) + 
((domain == null) ? "" : ("; domain=" + domain)) + 
((secure == true) ? "; secure" : ""); 
} 

function koekje(fname,fval) {
expir = new Date();
expir.setTime (expir.getTime() + 24 * 60 * 60 * 365 * 1000);
edat=expir.toGMTString();
SetCookie(fname,fval,edat,"/");
}

function addbookmark() {
if (document.all) window.external.AddFavorite("http://www.gizmoxia.be","Gizmoxia");
}

function setstart() {
if (document.all) {
 document.hmanga.verborgen.style.behavior='url(#default#homepage)';
 document.hmanga.verborgen.setHomePage('http://www.gizmoxia.be/');
 }
}

function profile(id) {
openhtms("profileshow.php?pid="+id,450,450);
}

function controlExpand(sup) {
var sub = document.all[(sup + 'sub')];
plaatje=document.all[(sup + 'gif')];
if (sub.style.display == 'none') {
 plaatje.src='images/icon_minus.gif';
 sub.style.display = '';
 } else {
 plaatje.src='images/icon_plus.gif';
 sub.style.display = 'none';
 }
}

function spExp(oid) {
 var Lyr;
 if ((navigator.appName == "Netscape") && (navigator.userAgent.indexOf("Gecko") == -1)) {
  if (document[oid].visibility != "show") {
   document[oid].visibility="show";
  } else {
   document[oid].visibility="hide";
  }
 } else {
  Lyr = document.getElementById(oid);
  if (Lyr.className == 'spoiler') {
   Lyr.className = 'spoilershow';
  } else {
   Lyr.className = 'spoiler';
  }
 }
}
