// sizematters.at - the best choice
if (window == top) top.location.href = "http://www.heirihaefliger.net";


var shows=new Array("00_1999_incontro","01_1999_west","02_1999_dove","03_2000_west","04_2000_verso","05_2000_bewilligte","06_2000_cultural","07_2000_ua","08_2000_chrysler","09_2000_juana","10_2000_vollendung","11_2001_obsorge","12_2001_marthaler","13_2001_west_app","14_2001_vogel","15_2002_english","16_2002_soho","17_2002_swiss_art","18_2002_asap","19_2003_auto","20_2003_capitain","21_2003_soho","22_2003_viandanti","23_2003_la_bas","24_2003_ordering","25_2003_21er","26_2004_etage","27_2004_beautiful","28_2004_elegant","29_2004_swiss_art","30_2004_lost_eight","31_2004_divers","32_2005_in_den_waeldern","33_2005_facts","34_2005_rein_raus","35_2005_bezieh","36_2005_summer","37_2006_knust","38_2006_mozart","39_2006_spiel","40_2006_zeitreise","41_2006_spontan","42_2006_enoe","43_2006_moya","44_2006_422","45_2006_villaMerkel","46_2007_tagsatz","47_2007_edelweiss","48_2007_souffle","49_2007_hamsterwheel-toulouse","50_2007_hamsterwheel-barcelona","51_2008_grazy","52_2008_tuttifrutti","53_2008_fruehwerk","54_2008_artmart","55_2008_baeckerstr","56_2009_haydn","57_2009_letzte_eck","58_2009_artaustria","59_2009_stalky","60_2009_review5","61_2009_naturamorte","62_2010_area53","63_2010_element6","64_2010_star","65_2008_rosas","66_2010_decor","67_2010_visite","68_2010_meister","69_2010_originalfunktional","70_2011_north","71_2011_holzwege","72_2011_hof","73_2011_unnoeti","74_2011_supererde");





var Eingabe = document.URL;
var numb1 = Eingabe.substring(40, 42);
var showNumber = (Number(numb1));


function GetAllShows(){
var allshows=shows.length;
return allshows;
}


function works(i)
{
var url1 ="../html/text/"+shows[i]+"_t.html";
var url2 ="../html/bild/"+shows[i]+"_b.html";
parent.frames[1].location.href=url1;
parent.frames[2].location.href=url2;
}

function works_shortcut(i)
{
var url1 ="../text/"+shows[i]+"_t.html";
var url2 =shows[i]+"_b.html";
parent.frames[1].location.href=url1;
parent.frames[2].location.href=url2;
}
function backHome()
{
var url1 ="../../html/weiss.html";
var url2 ="../../html/biografie.html";
parent.frames[1].location.href=url1;
parent.frames[2].location.href=url2;
}

function frameSwitch(url1,F1,url2,F2)
{
parent.frames[F1].location.href=url1;
parent.frames[F2].location.href=url2;
}

function shortcut(showNumber)
{
if(showNumber == 0){
x = shows.length-1;
}else{
x = showNumber - 1;}
if(showNumber == shows.length-1){
y = 0;
}else{
y = showNumber + 1;}
var txt= "<a href=\"javascript:works_shortcut("+x+")\" title=\"vorige\"><img src=\"../../images/back.gif\" width=\"15\" height=\"15\" class=\"back\" /></a>";
txt+="<span class=\"backHome\"><a href=\"javascript:backHome()\">&Uuml;bersicht</a></span>";
txt+="<a href=\"javascript:works_shortcut("+y+")\" title=\"naechste\"><img src=\"../../images/forward.gif\" width=\"15\" height=\"15\" class=\"forward\" /></a>";
document.write(txt);
}

function infos(showNumber)
{
var infoURL ="../text/"+shows[showNumber]+"_t.html";
var infolink= "<a href=\""+infoURL+"\" target=\"links\">Info</a>";
document.write(infolink);
}

// writelinks

var bodydef="<body>";
function write_body() {
	parent.links.window.document.open("text/html");
	parent.links.window.document.write("<html><head><title></title></head>" + bodydef + "<div  style=\"text-align:right; font-family: verdana, arial, helvetica, sans-serif;font-size:9px;\">");
}

function close_html() {
    parent.links.window.document.write("</div></body></html>");
	parent.links.window.document.close();
}

function automaticLeft(nummer,ext){
	write_body()
	bildurl="<img src=\"../../images/big/" + nummer + "_bi." + ext + "\" vspace=\"1\" alt=\"Bild wird geladen...\">";
	parent.links.window.document.write(bildurl);  close_html();
}

// popup 

function MM_openBrWindow(theURL,winName,features) { //v2.0
  window.open(theURL,winName,features);
  }
  
// vogelgezwitscher popup-center 

var win = null;
function NewWindow(mypage,myname,w,h,scroll) {
  if (win != null) 
  {
        if (!win.closed) {
                win.close();
        }
LeftPosition = (screen.width) ? (screen.width-w)/2 : 0;
TopPosition = (screen.height) ? (screen.height-h)/2 : 0;
settings ='height='+h+',width='+w+',top='+TopPosition+',left='+LeftPosition+',scrollbars='+scroll+',resizable=0'
win = window.open(mypage,myname,settings)
}
  if (win == null) {
LeftPosition = (screen.width) ? (screen.width-w)/2 : 0;
TopPosition = (screen.height) ? (screen.height-h)/2 : 0;
settings ='height='+h+',width='+w+',top='+TopPosition+',left='+LeftPosition+',scrollbars='+scroll+',resizable=0'
win = window.open(mypage,myname,settings)
}
}

// antispam

var contacts=new Array();
contacts[0]=["net[at]heirihaefliger[dot]net",""];

function displaycontact(emailarray)
{
//else if it is a single array element
document.write('<a href="mailto:' + modifyemail(emailarray[0])+ '">'+ modifyemail(emailarray[0]) + '</a>')
}

function displaycontactalt(emailarray)
{
//else if it is a single array element
document.write('<a href="mailto:' + modifyemail(emailarray[0])+ '">'+ modifyemail(emailarray[1]) + '</a>')
}

function modifyemail(emailitem){
var modified=emailitem.replace(/\[at]/gi, "@")
modified=modified.replace(/\[dot]/gi, ".")
return modified
}
