var psgmbh = false;

var PSMenu = new menu("PSMenu");
PSMenu.offColor = "silver";
PSMenu.onColor = "gray";

function writeMenu(showpartner) {
	// befindet sich der Besucher im Partnerbereich,
	// müssen die Links angepasst werden
	var url = "";
	if (location.href.indexOf("/partnerbereich/") >= 0) {
		url = "../../gb/";
	}

	var Customers      = PSMenu.add("Customers", url + "applications.html", 98);
		var Applications = Customers.add("Applications", url + "applications.html", 110);
			Applications.add("Compressors", url + "applications-co.html");
			Applications.add("General Engineering", url + "applications-ge.html", 200);
			Applications.add("Hydropower", url + "applications-hp.html");
			Applications.add("Mining", url + "applications-mi.html");
			Applications.add("Petrochemistry", url + "applications-pc.html");
			Applications.add("Presses", url + "applications-pr.html");
			Applications.add("Shipbuilding", url + "applications-sb.html");
			Applications.add("Steel Industry", url + "applications-st.html");
			Applications.add("Thermal Power Station", url + "applications-tp.html");
			Applications.add("Wind Energy", url + "applications-we.html");

	var Contact     = PSMenu.add("Contact", url + "head-office.html");
		Contact.add("Head Office", url + "head-office.html", 230);
		Contact.add("Branch", url + "branch.html");
		var Europe = Contact.add("Representatives in Europe", url + "representatives-europe.html");
			Europe.add("Austria", url + "representatives-austria.html");
			Europe.add("Benelux", url + "representatives-benelux.html", 120);
			Europe.add("Bulgaria", url + "representatives-romania-bulgaria.html");
			Europe.add("Cyprus", url + "representatives-greece-cyprus.html");
			Europe.add("Czech Republic", url + "representatives-czech-republic.html");
			Europe.add("Denmark", url + "representatives-denmark.html");
			Europe.add("Finland", url + "representatives-finland.html");
			Europe.add("France", url + "representatives-france.html");
			Europe.add("Germany", url + "representatives-germany.html");
			Europe.add("Great Britain", url + "representatives-great-britain.html");
			Europe.add("Greece", url + "representatives-greece-cyprus.html");
			Europe.add("Hungary", url + "representatives-hungary.html");
			Europe.add("Italy", url + "representatives-italy.html");
			Europe.add("Netherlands", url + "representatives-netherlands.html");
			Europe.add("Norway", url + "representatives-norway.html");
			Europe.add("Poland", url + "representatives-poland.html");
			Europe.add("Portugal", url + "representatives-portugal.html");
			Europe.add("Romania", url + "representatives-romania-bulgaria.html");
			Europe.add("Russia", url + "representatives-russia.html");
			Europe.add("Slovakia", url + "representatives-slovakia.html");
			Europe.add("Spain", url + "representatives-spain.html");
			Europe.add("Sweden", url + "representatives-sweden.html");
			Europe.add("Turkey", url + "representatives-turkey.html");
		var Outside = Contact.add("Outside Europe", url + "representatives-outside-europe.html");
			Outside.add("Iran", url + "representatives-iran.html", 120);			
			Outside.add("Maghreb", url + "representatives-maghreb.html");
			Outside.add("Other Countries", url + "representatives-superbolt.html");
		
		Contact.add("Certificates", url + "certificates.html");
		Contact.add("Contact Form", url + "information-order.html");

	var News = PSMenu.add("News", url + "events.html");
		News.add("Events and Exhibitions", url + "events.html", 200);
		News.add("Press Reports", url + "press.html");

	var Products    = PSMenu.add("Products", url + "concept.html");
		Products.add("Concept", url + "concept.html", 200);
		Products.add("Advantages", url + "advantages.html");
		var Catalogue = Products.add("Catalogue", url + "mechanical-tensioners.html");
			var MechanicalTensioners = Catalogue.add("Mechanical Tensioners", url + "mechanical-tensioners.html", 200);
				MechanicalTensioners.add("MT", url + "datasheet-mt.html", 100);
				MechanicalTensioners.add("MTT", url + "datasheet-mtt.html");
				MechanicalTensioners.add("MTL", url + "datasheet-mtl.html");
				MechanicalTensioners.add("MR", url + "datasheet-mr.html");
				MechanicalTensioners.add("MRA", url + "datasheet-mra.html");
				MechanicalTensioners.add("CY", url + "datasheet-cy.html");
				MechanicalTensioners.add("SJ", url + "datasheet-sj.html");
				MechanicalTensioners.add("SJL", url + "datasheet-sjl.html");
				MechanicalTensioners.add("SJX", url + "datasheet-sjx.html");
				MechanicalTensioners.add("GR2", url + "datasheet-gr2.html");
				MechanicalTensioners.add("CN", url + "datasheet-cn.html");
				MechanicalTensioners.add("SP", url + "datasheet-sp.html");
				MechanicalTensioners.add("NM", url + "datasheet-nm.html");
				MechanicalTensioners.add("SM", url + "datasheet-sm.html");
				MechanicalTensioners.add("H650", url + "datasheet-h650.html");
				MechanicalTensioners.add("H650T", url + "datasheet-h650t.html");
				MechanicalTensioners.add("PV350C", url + "datasheet-pvc350c.html");
				MechanicalTensioners.add("PV450C", url + "datasheet-pvc450c.html");
				MechanicalTensioners.add("H850T", url + "datasheet-h850t.html");
				MechanicalTensioners.add("SH", url + "datasheet-sh.html");
				MechanicalTensioners.add("SHT", url + "datasheet-sht.html");
			var ExpansionBolts = Catalogue.add("Expansion Bolts", url + "expansionbolts.html");
				ExpansionBolts.add("EBC", "datasheet-ebc.html");
			var TorqueBolts = Catalogue.add("Torque Bolts", url + "torquebolts.html");
				TorqueBolts.add("SB8", url + "datasheet-sb8.html", 90);
				TorqueBolts.add("SB12", url + "datasheet-sb12.html");
				TorqueBolts.add("SBU", url + "datasheet-sbu.html");
				TorqueBolts.add("SSJ", url + "datasheet-ssj.html");
			var SpecialSolutions = Catalogue.add("Special Solutions", url + "special-solutions.html");
				SpecialSolutions.add("SX8-series", url + "datasheet-sx8.html", 90);
				SpecialSolutions.add("SX12-series", url + "datasheet-sx12.html");
			var Accessories = Catalogue.add("Accessories", url + "accessories.html");
				Accessories.add("Tools", url + "datasheet-tools.html", 90);
				Accessories.add("CAP INOX", url + "datasheet-cap-inox.html");
				Accessories.add("CAP PVC", url + "datasheet-cap-pvc.html");
		Products.add("Instructions", url + "instructions.html");
		Products.add("Request for Information", url + "information-order.html");

	// befindet sich der Benutzer nicht im Partnerbereich, müssen die Links zum
	// Partnerbereich angepasst werden
	if (url == "") {
		url = "../partnerbereich/gb/";
	}
	else {
		url = "";
	}
	var Partner = PSMenu.add("Partner", url + "salesreports.html");
	if (showpartner) {
		Partner.add("Sales Reports", url + "salesreports.html");
		Partner.add("Data Sheets", url + "datasheets.html");
		var Downloads = Partner.add("Downloads", url + "prospectus.html");
			Downloads.add("Prospectus", url + "prospectus.html");
			Downloads.add("Supplementary Instructions", url + "suppinstr.html");
			Downloads.add("Publications", url + "publications.html");
			Downloads.add("Technical Reports/Basics", url + "technicalreports.html");
			Downloads.add("Video", url + "video/superbolt_gb.mpg");
		Partner.add("References", url + "references.html");
	}

	PSMenu.create();
}
