/***********************************************
Versionswechsel deutsch-englisch
***********************************************/
function EnglishVersion() {
var doc_url = document.URL;
var messename = doc_url.indexOf("messename");

if (messename != -1) {
 doc_url = doc_url;
} else {
var doc_url = doc_url.replace(/deutsch/,"englisch");
}
location.replace(doc_url);
}
function GermanVersion() {
var doc_url = document.URL;
var messename = doc_url.indexOf("messename");

if (messename != -1) {
 doc_url = doc_url;
} else {
var doc_url = doc_url.replace(/englisch/,"deutsch");
}
location.replace(doc_url);
}

/***********************************************
versteckte DIVs zum aufklappen
***********************************************/
function toggledisplay (id, indicator){ 
	if (document.getElementById) { 
		var obj = document.getElementById(id);
		var pic = document.getElementsByName(indicator);
		obj.style.display = (obj.style.display=='block'?'none':'block');
		pic[0].src = (obj.style.display=='block'?'/bilder/hide.gif':'/bilder/show.gif');
	} else if(document.all) { // IE
		id.style.display = (id.style.display=='block'?'none':'block');
		indicator.src = (id.style.display=='block'?'/bilder/hide.gif':'/bilder/show.gif');
	} else if (document.layers) { // Netscape 4.x
		document.id.style.display = (document.id.style.display=='block'?'none':'block');
		document.indicator.src = (document.id.style.display=='block'?'/bilder/hide.gif':'/bilder/show.gif');
	}
}

// www: http://www.javarea.de
// Copyright by javarea.de

// Link[nr] = 'position [0 is menu/1 is item] | Link name | url | target (blank|top|frame_name)'
var Link = new Array();

Link[0] = '0|&nbsp;&nbsp;Bitte wählen Sie:';
Link[1] = '1|&nbsp;&nbsp;Belgien|http://www.igedo.com/IGEDO/website/deutsch/igedo/1_company/ausland/Belgien.php|ausland';
Link[2] = '1|&nbsp;&nbsp;Dänemark, Island, Färöer Inseln|http://www.igedo.com/IGEDO/website/deutsch/igedo/1_company/ausland/Daenemark.php|ausland';
Link[3] = '1|&nbsp;&nbsp;Finnland|http://www.igedo.com/IGEDO/website/deutsch/igedo/1_company/ausland/Finnland.php|ausland';
Link[4] = '1|&nbsp;&nbsp;Frankreich|http://www.igedo.com/IGEDO/website/deutsch/igedo/1_company/ausland/Frankreich.php|ausland';
Link[5] = '1|&nbsp;&nbsp;Großbritannien, Irland|http://www.igedo.com/IGEDO/website/deutsch/igedo/1_company/ausland/Grossbritannien.php|ausland';
Link[6] = '1|&nbsp;&nbsp;GUS|http://www.igedo.com/IGEDO/website/deutsch/igedo/1_company/ausland/GUS.php|ausland';
Link[7] = '1|&nbsp;&nbsp;Italien|http://www.igedo.com/IGEDO/website/deutsch/igedo/1_company/ausland/Italien.php|ausland';
Link[8] = '1|&nbsp;&nbsp;Niederlande|http://www.igedo.com/IGEDO/website/deutsch/igedo/1_company/ausland/Niederlande.php|ausland';
Link[9] = '1|&nbsp;&nbsp;Österreich|http://www.igedo.com/IGEDO/website/deutsch/igedo/1_company/ausland/Oesterreich.php|ausland';
Link[10] = '1|&nbsp;&nbsp;Polen|http://www.igedo.com/IGEDO/website/deutsch/igedo/1_company/ausland/Polen.php|ausland';
Link[11] = '1|&nbsp;&nbsp;Schweden|http://www.igedo.com/IGEDO/website/deutsch/igedo/1_company/ausland/Schweden.php|ausland';
Link[12] = '1|&nbsp;&nbsp;Spanien|http://www.igedo.com/IGEDO/website/deutsch/igedo/1_company/ausland/Spanien.php|ausland';

var height    = 20; // Hoehe der Menuekoepfe
var iheight   = 15; // Hoehe der Menueelemente
var bgc       = '#c4c4c4' // background color of the item
var over_bgc  = '#515151';
var tc        = '#606060' // text color of the item
var over_tc   = '#ffffff';
var speed     = 0;
var timerID   = 0;
var width     = 310;
var N         = (document.all) ? 0 : 1;
var self_menu = new Array();

function write_menu()
{
	smc   = 0;
	mn    = 0;
	mni   = 1;
	start = -1;

	document.write('<div style="position: absolute;">');

	for (var i = 0; i < Link.length; i++)
	{
		la = Link[i].split('|');

		if (la[0] == 0)
		{
			if (start == 0)
			{
				document.write('</div>');

				h = csmc * iheight;
				tmn = mn; // - h;
				self_menu[smc] = new Array(tmn, h, 0, -2);

				smc++;
				mn--;
			}

			csmc = 0;

			document.write('<div id="down' + smc + '" class="menu" '
			             + 'style="top: ' + mn + 'px; height: ' + height + 'px;" '
			             + 'onclick="pull_down(' + smc + ', ' + mni + ');">'
			             + '  ' + la[1] + '</div>');

			self_menu[smc] = new Array(mn, height, 0, mni);

			smc++;
			mni++;
			mn += height;
			start = 1;
		}
		else
		{
			if (start == 1)
			{
				if (N)
					mn += 2;

				document.write('<div id="down' + smc + '" class="item_panel" '
				             + 'style="top: '+ mn + 'px;">');

				start = 0;
			}

			document.write('<a href="' + la[2] + '"'
			             + ((la[3] != '') ? ' target="' + la[3] + '"' : '')
			             + '><div id="d' + i + '" class="item" '
			             + 'style="height: ' + iheight + 'px;'
			             + ((N) ? ' width:308px;' : '')
			             + '" onmouseover="color(this.id);" '
			             + 'onmouseout="uncolor(this.id);">'
			             + ' ' + la[1] + '</div></a>');

			csmc++;
		}
	}

	if (start == 0)
	{
		document.write('</div>');

		h =  csmc * iheight;
		tmn = mn + 5; // - h;
		self_menu[smc] = new Array(tmn, h, 0);
		name = 'down' + (self_menu.length - 1);

		obj = document.getElementById(name);
		obj.style.borderBottomColor = '#1c8d89';
		obj.style.borderBottomWidth = '1px';
		obj.style.borderBottomStyle = 'solid';
	}

	document.write('</div>');
}

function color(obj)
{
	document.getElementById(obj).style.backgroundColor = over_bgc;
	document.getElementById(obj).style.color = over_tc;
}

function uncolor(obj)
{
	document.getElementById(obj).style.backgroundColor = bgc;
	document.getElementById(obj).style.color = tc;
}

function pull_down(nr, c)
{
	if (timerID == '')
	{
		to = self_menu[nr + 1][1]
		begin = nr + 2;

		if (timerID != '')
			clearTimeout(timerID);

		if (self_menu[nr + 1][2] == 0)
		{
			self_menu[nr + 1][2] = 1;

			if (nr == (self_menu.length - 2))
				to++;

			epull_down(begin, to, 0);
		}
		else
		{
			to = 0;
			self_menu[nr + 1][2] = 0;
			name = 'down' + (nr + 2);
			open_item = 0;

			for (var i = 0; i < nr; i++)
				if (self_menu[i][2] == 1)
					open_item += self_menu[i][1];

			if (N == false)
				open_item -= (c * 1);

			if (nr == (self_menu.length - 2))
			{
				val = self_menu[self_menu.length - 1][1];
				to = -1;
			}
			else
				val = parseInt(document.getElementById(name).style.top) - (open_item) - (c * height);

			epull_up(begin, to, val);
		}
	}
}

function epull_down(nr, to, nowv)
{
	name = 'down' + (nr - 1);
	obj = document.getElementById(name).style.clip = 'rect(0, ' + width + ', ' + (nowv + 1) + ', 0)';

	for (var i = nr; i < self_menu.length; i++)
	{
		name = 'down' + i;
		obj = document.getElementById(name);
		obj.style.top = parseInt(obj.style.top) + 1;
	}

	nowv++;

	if (nowv < to)
		timerID = setTimeout('epull_down(' + nr + ', ' + to + ', ' + nowv + ');', speed);
	else
		timerID = 0;
}

function epull_up(nr, to, nowv)
{
	name = 'down' + (nr - 1);
	obj = document.getElementById(name).style.clip = 'rect(0, ' + width + ', ' + nowv + ', 0)';

	for (var i = nr; i < self_menu.length; i++)
	{
		name = 'down' + i;
		obj = document.getElementById(name);
		obj.style.top = parseInt(obj.style.top) - 1;
	}

	nowv--;

	if(nowv > to)
		timerID = setTimeout('epull_up(' + nr + ', ' + to + ', ' + nowv + ');', speed);
	else
		timerID = 0;
}

function startup(nr)
{
	write_menu();

	if (nr != 0)
	{
		for (var i = 0; i < self_menu.length; i++)
		{
			if (self_menu[i][3] == nr)
				pull_down(i, nr);

			i == self_menu.length;
		}
	}
}

/***********************************************
* Ultimate Fade-In Slideshow (v1.51): © Dynamic Drive (http://www.dynamicdrive.com)
* This notice MUST stay intact for legal use
* Visit http://www.dynamicdrive.com/ for this script and 100s more.
***********************************************/
 
var fadeimages=new Array()
//SET IMAGE PATHS. Extend or contract array as needed
//new fadeshow(IMAGES_ARRAY_NAME, slideshow_width, slideshow_height, borderwidth, delay, pause (0=no, 1=yes), optionalRandomOrder)
fadeimages[0]=["photo1.jpg", "", ""] //plain image syntax
fadeimages[1]=["photo2.jpg", "http://www.cssdrive.com", ""] //image with link syntax
fadeimages[2]=["photo3.jpg", "http://www.javascriptkit.com", "_new"] //image with link and target syntax
 
var fadeimages2=new Array()
fadeimages2[0]=["/IGEDO/pics/igedo/messereiseservice2.jpg", "", ""]
fadeimages2[1]=["/IGEDO/pics/igedo/reiseservice", "", ""]

var fadeimages3=new Array()
fadeimages3[0]=["/IGEDO/pics/igedo/kontakt.jpg", "", ""]
fadeimages3[1]=["/IGEDO/pics/igedo/kontakt2.jpg", "", ""]

var fadeimages2e=new Array()
fadeimages2e[0]=["/IGEDO/pics/igedo/messereiseservice2-e.jpg", "", ""]
fadeimages2e[1]=["/IGEDO/pics/igedo/messereiseservice-e.jpg", "", ""]

var fadeimages3e=new Array()
fadeimages3e[0]=["/IGEDO/pics/igedo/kontakt-e.jpg", "", ""]
fadeimages3e[1]=["/IGEDO/pics/igedo/kontakt2-e.jpg", "", ""]

var fadeimages5e=new Array()
fadeimages5e[0]=["/IGEDO/pics/igedo/service1-e.jpg", "", ""]
fadeimages5e[1]=["/IGEDO/pics/igedo/service2-e.jpg", "", ""]
 
var fadebgcolor="white"

////NO need to edit beyond here/////////////
 
var fadearray=new Array() //array to cache fadeshow instances
var fadeclear=new Array() //array to cache corresponding clearinterval pointers
 
var dom=(document.getElementById) //modern dom browsers
var iebrowser=document.all
 
function fadeshow(theimages, fadewidth, fadeheight, borderwidth, delay, pause, displayorder){
this.pausecheck=pause
this.mouseovercheck=0
this.delay=delay
this.degree=10 //initial opacity degree (10%)
this.curimageindex=0
this.nextimageindex=1
fadearray[fadearray.length]=this
this.slideshowid=fadearray.length-1
this.canvasbase="canvas"+this.slideshowid
this.curcanvas=this.canvasbase+"_0"
if (typeof displayorder!="undefined")
theimages.sort(function() {return 0.5 - Math.random();}) //thanks to Mike (aka Mwinter) :)
this.theimages=theimages
this.imageborder=parseInt(borderwidth)
this.postimages=new Array() //preload images
for (p=0;p<theimages.length;p++){
this.postimages[p]=new Image()
this.postimages[p].src=theimages[p][0]
}
 
var fadewidth=fadewidth+this.imageborder*2
var fadeheight=fadeheight+this.imageborder*2
 
if (iebrowser&&dom||dom) //if IE5+ or modern browsers (ie: Firefox)
document.write('<div id="master'+this.slideshowid+'" style="position:relative;width:'+fadewidth+'px;height:'+fadeheight+'px;overflow:hidden;"><div id="'+this.canvasbase+'_0" style="position:absolute;width:'+fadewidth+'px;height:'+fadeheight+'px;top:0;left:0;filter:progid:DXImageTransform.Microsoft.alpha(opacity=10);opacity:0.1;-moz-opacity:0.1;-khtml-opacity:0.1;background-color:'+fadebgcolor+'"></div><div id="'+this.canvasbase+'_1" style="position:absolute;width:'+fadewidth+'px;height:'+fadeheight+'px;top:0;left:0;filter:progid:DXImageTransform.Microsoft.alpha(opacity=10);opacity:0.1;-moz-opacity:0.1;-khtml-opacity:0.1;background-color:'+fadebgcolor+'"></div></div>')
else
document.write('<div><img name="defaultslide'+this.slideshowid+'" src="'+this.postimages[0].src+'"></div>')
 
if (iebrowser&&dom||dom) //if IE5+ or modern browsers such as Firefox
this.startit()
else{
this.curimageindex++
setInterval("fadearray["+this.slideshowid+"].rotateimage()", this.delay)
}
}

function fadepic(obj){
if (obj.degree<100){
obj.degree+=10
if (obj.tempobj.filters&&obj.tempobj.filters[0]){
if (typeof obj.tempobj.filters[0].opacity=="number") //if IE6+
obj.tempobj.filters[0].opacity=obj.degree
else //else if IE5.5-
obj.tempobj.style.filter="alpha(opacity="+obj.degree+")"
}
else if (obj.tempobj.style.MozOpacity)
obj.tempobj.style.MozOpacity=obj.degree/101
else if (obj.tempobj.style.KhtmlOpacity)
obj.tempobj.style.KhtmlOpacity=obj.degree/100
else if (obj.tempobj.style.opacity&&!obj.tempobj.filters)
obj.tempobj.style.opacity=obj.degree/101
}
else{
clearInterval(fadeclear[obj.slideshowid])
obj.nextcanvas=(obj.curcanvas==obj.canvasbase+"_0")? obj.canvasbase+"_0" : obj.canvasbase+"_1"
obj.tempobj=iebrowser? iebrowser[obj.nextcanvas] : document.getElementById(obj.nextcanvas)
obj.populateslide(obj.tempobj, obj.nextimageindex)
obj.nextimageindex=(obj.nextimageindex<obj.postimages.length-1)? obj.nextimageindex+1 : 0
setTimeout("fadearray["+obj.slideshowid+"].rotateimage()", obj.delay)
}
}
 
fadeshow.prototype.populateslide=function(picobj, picindex){
var slideHTML=""
if (this.theimages[picindex][1]!="") //if associated link exists for image
slideHTML='<a href="'+this.theimages[picindex][1]+'" target="'+this.theimages[picindex][2]+'">'
slideHTML+='<img src="'+this.postimages[picindex].src+'" border="'+this.imageborder+'px">'
if (this.theimages[picindex][1]!="") //if associated link exists for image
slideHTML+='</a>'
picobj.innerHTML=slideHTML
}
 
 
fadeshow.prototype.rotateimage=function(){
if (this.pausecheck==1) //if pause onMouseover enabled, cache object
var cacheobj=this
if (this.mouseovercheck==1)
setTimeout(function(){cacheobj.rotateimage()}, 100)
else if (iebrowser&&dom||dom){
this.resetit()
var crossobj=this.tempobj=iebrowser? iebrowser[this.curcanvas] : document.getElementById(this.curcanvas)
crossobj.style.zIndex++
fadeclear[this.slideshowid]=setInterval("fadepic(fadearray["+this.slideshowid+"])",50)
this.curcanvas=(this.curcanvas==this.canvasbase+"_0")? this.canvasbase+"_1" : this.canvasbase+"_0"
}
else{
var ns4imgobj=document.images['defaultslide'+this.slideshowid]
ns4imgobj.src=this.postimages[this.curimageindex].src
}
this.curimageindex=(this.curimageindex<this.postimages.length-1)? this.curimageindex+1 : 0
}
 
fadeshow.prototype.resetit=function(){
this.degree=10
var crossobj=iebrowser? iebrowser[this.curcanvas] : document.getElementById(this.curcanvas)
if (crossobj.filters&&crossobj.filters[0]){
if (typeof crossobj.filters[0].opacity=="number") //if IE6+
crossobj.filters(0).opacity=this.degree
else //else if IE5.5-
crossobj.style.filter="alpha(opacity="+this.degree+")"
}
else if (crossobj.style.MozOpacity)
crossobj.style.MozOpacity=this.degree/101
else if (crossobj.style.KhtmlOpacity)
crossobj.style.KhtmlOpacity=this.degree/100
else if (crossobj.style.opacity&&!crossobj.filters)
crossobj.style.opacity=this.degree/101
}
 
 
fadeshow.prototype.startit=function(){
var crossobj=iebrowser? iebrowser[this.curcanvas] : document.getElementById(this.curcanvas)
this.populateslide(crossobj, this.curimageindex)
if (this.pausecheck==1){ //IF SLIDESHOW SHOULD PAUSE ONMOUSEOVER
var cacheobj=this
var crossobjcontainer=iebrowser? iebrowser["master"+this.slideshowid] : document.getElementById("master"+this.slideshowid)
crossobjcontainer.onmouseover=function(){cacheobj.mouseovercheck=1}
crossobjcontainer.onmouseout=function(){cacheobj.mouseovercheck=0}
}
this.rotateimage()
}