var clicked=""
var gtype=".gif"
var selstate="_over"
if (typeof(loc)=="undefined" || loc==""){
	var loc=""
	if (document.body&&document.body.innerHTML){
		var tt = document.body.innerHTML.toLowerCase();
		var last = tt.indexOf("typewriter2.js\"");
		if (last>0){
			var first = tt.lastIndexOf("\"", last);
			if (first>0 && first<last) loc = document.body.innerHTML.substr(first+1,last-first-1);
		}
	}
}

document.write("<table border=\"0\" cellspacing=\"0\" cellpadding=\"0\"><tr>");
document.write("<td><img src=\""+loc+"typewriter2_top.gif\" alt=\"\" width=\"108\" height=\"15\"></td>");
tr(false);
writeButton("","http://www.islands-brygge.com/nede.htm","typewriter2_b1",108,21,"Forside","nederst",0);
writeButton("","http://www.islands-brygge.com/fotos.htm","typewriter2_b2",108,21,"Fotos","nederst",0);
writeButton("","http://www.islands-brygge.com/bornenes.htm","typewriter2_b3",108,21,"Fotos fra Skolen","nederst",0);
writeButton("","http://www.islands-brygge.com/Historie.htm","typewriter2_b4",108,21,"Fotos 1899-2004","nederst",0);
writeButton("","http://www.islands-brygge.com/underholdning.htm","typewriter2_b5",108,21,"Havnebad","nederst",0);
writeButton("","http://www.islands-brygge.com/spisesteder.htm","typewriter2_b6",108,21,"Spisesteder","nederst",0);
writeButton("","http://www.islands-brygge.com/detsker.htm","typewriter2_b7",108,21,"Det sker på Bryggen","nederst",0);
writeButton("","http://www.islands-brygge.com/foreninger.htm","typewriter2_b8",108,21,"Foreninger ol.","nederst",0);
writeButton("","http://www.islands-brygge.com/forretninger.htm","typewriter2_b9",108,21,"Forretninger","nederst",0);
writeButton("","http://www.islands-brygge.com/indledningkinesisk.htm","typewriter2_b10",108,21,"Kinesisk Astrologi","nederst",0);
writeButton("","http://www.islands-brygge.com/tarot.htm","typewriter2_b11",108,21,"Træk Tarotkort","nederst",0);
writeButton("","http://www.islands-brygge.com/pizza.htm","typewriter2_b12",108,21,"Underlig Pizza","nederst",0);
writeButton("","http://www.islands-brygge.com/links.htm","typewriter2_b13",108,21,"Links","nederst",0);
writeButton("","http://www.islands-brygge.com/kontakt.htm","typewriter2_b14",108,21,"Kontakt","nederst",0);
writeButton("","http://www.islands-brygge.com/trailere.htm","typewriter2_b15",108,21,"Filmtrailers","nederst",0);
writeButton("","http://www.islands-brygge.com/gaestebog.htm","typewriter2_b16",108,21,"Gæstebog","nederst",0);
writeButton("","http://bryggenet.dk/forum/","typewriter2_b17",108,21,"Bryggedebat","",0);
tr(true);
document.write("<td><img src=\""+loc+"typewriter2_bottom.gif\" alt=\"\" width=\"108\" height=\"16\"></td>");
document.write("</tr></table>")
loc="";

function tr(b){if (b) document.write("<tr>");else document.write("</tr>");}

function turn_over(name) {
	if (document.images != null && clicked != name) {
		document[name].src = document[name+"_over"].src;
	}
}

function turn_off(name) {
	if (document.images != null && clicked != name) {
		document[name].src = document[name+"_off"].src;
	}
}

function reg(gname,name)
{
if (document.images)
	{
	document[name+"_off"] = new Image();
	document[name+"_off"].src = loc+gname+gtype;
	document[name+"_over"] = new Image();
	document[name+"_over"].src = loc+gname+"_over"+gtype;
	}
}

function evs(name){ return " onmouseover=\"turn_over('"+ name + "')\" onmouseout=\"turn_off('"+ name + "')\""}

function writeButton(urld, url, name, w, h, alt, target, hsp)
{
	gname = name;
	while(typeof(document[name])!="undefined") name += "x";
	reg(gname, name);
	tr(true);
	document.write("<td>");
	if (alt != "") alt = " alt=\"" + alt + "\"";
	if (target != "") target = " target=\"" + target + "\"";
	if (w > 0) w = " width=\""+w+"\""; else w = "";
	if (h > 0) h = " height=\""+h+"\""; else h = "";	
	if (url != "") url = " href=\"" + urld + url + "\"";
	
	document.write("<a " + url + evs(name) + target + ">");	
	
	if (hsp == -1) hsp =" align=\"right\"";
	else if (hsp > 0) hsp = " hspace=\""+hsp+"\"";
	else hsp = "";
	
	document.write("<img src=\""+loc+gname+gtype+"\" name=\"" + name + "\"" + w + h + alt + hsp + " border=\"0\" /></a></td>");
	tr(false);
}
