
/*
 * jQuery 1.2.6 - New Wave Javascript
 *
 * Copyright (c) 2008 John Resig (jquery.com)
 * Dual licensed under the MIT (MIT-LICENSE.txt)
 * and GPL (GPL-LICENSE.txt) licenses.
 *
 * $Date: 2008-05-24 14:22:17 -0400 (Sat, 24 May 2008) $
 * $Rev: 5685 $
 */



function changeLanguage(select)
{
  var wert = select.options[select.options.selectedIndex].value;
  var url = 'index.php?language=' + wert;
  location.href= url;
}

function getsupport ( selectedtype )
{
  document.supportform.supporttype.value = selectedtype ;
  document.supportform.submit() ;
}

function confirmDelete()
{
  return confirm("Wollen Sie wirklich loeschen?");
}

function check_it(add_product_form)
{
  if(add_product_form.product_title.value == '')
  {
    alert('Enter Product Title.');
    return false;
   }
}

function blockError()
{
  return true;
}

window.onerror = blockError;


// 9) change the image based on if the box is active or not
////----------------------------------------------------------------
  $(document).ready(function(){
  
/*
  
    $('.subnav').css('display','block');
    $('.subnav2').css('display','block');
    $('.subnav3').css('display','block');
*/

  
  
  
	$(".sub_nav").hide();
/* 	$('').insertAfter('a h3'); 				    */
	$("a h3").click(function(){
		if($(this).is(".active")) {
         $(this).toggleClass("active");
/* 		 $('.arrow.active').attr('src','arrow-down.png'); // change the image src of the current ACTIVE image to have an INACTIVE state. */
         $(this).parent().next(".sub_nav").slideToggle();
         return false;
		} else {
			$(".sub_nav:visible").slideUp("slow"); // close all visible divs with the class of .sub_nav
			$(".sub_nav2:visible").slideUp("slow"); // close all visible divs with the class of .sub_nav

			$("h3.active").removeClass("active");  // remove the class active from all h3's with the class of .active
			$("h4.active").removeClass("active");  // remove the class active from all h3's with the class of .active

			$(this).toggleClass("active");
/* 			$('.arrow.active').attr('src','arrow-down.png'); // change the image src of the current ACTIVE image to have an INACTIVE state. */
/* 			$(".arrow").addClass('active'); */
/* 			$(this).siblings('.arrow.active').attr('src','arrow-up.png'); // change the image src of the new active image to have an active state. */
			$(this).parent().next(".sub_nav").slideToggle();
			return false;
		}
	});
});



// 9) change the image based on if the box is active or not
////----------------------------------------------------------------
  $(document).ready(function(){
	$(".sub_nav2").hide();
/* 	$('<img src="" class="arrow" />').insertAfter('a h4'); 				    */
	$("a h4").click(function(){
		if($(this).is(".active")) {
         $(this).toggleClass("active");
/* 		 $('.arrow.active').attr('src','arrow-down.png'); // change the image src of the current ACTIVE image to have an INACTIVE state. */
         $(this).parent().next(".sub_nav2").slideToggle();
         return false;
		} else {
			$(".sub_nav2:visible").slideUp("slow"); // close all visible divs with the class of .sub_nav
			$("h4.active").removeClass("active");  // remove the class active from all h3's with the class of .active
			$(this).toggleClass("active");
/*
			$('.arrow.active').attr('src','arrow-down.png'); // change the image src of the current ACTIVE image to have an INACTIVE state.
			$(".arrow").addClass('active');
			$(this).siblings('.arrow.active').attr('src','arrow-up.png'); // change the image src of the new active image to have an active state.
*/
			$(this).parent().next(".sub_nav2").slideToggle();
			return false;
		}
	});
});

// 9) change the image based on if the box is active or not
////----------------------------------------------------------------
  $(document).ready(function(){
	$(".sub_nav3").hide();
/* 	$('<img src="" class="arrow" />').insertAfter('a h4'); 				    */
	$("a h5").click(function(){
		if($(this).is(".active")) {
         $(this).toggleClass("active");
/* 		 $('.arrow.active').attr('src','arrow-down.png'); // change the image src of the current ACTIVE image to have an INACTIVE state. */
         $(this).parent().next(".sub_nav3").slideToggle();
         return false;
		} else {
			$(".sub_nav3:visible").slideUp("slow"); // close all visible divs with the class of .sub_nav
			$("h5.active").removeClass("active");  // remove the class active from all h3's with the class of .active
			$(this).toggleClass("active");
/*
			$('.arrow.active').attr('src','arrow-down.png'); // change the image src of the current ACTIVE image to have an INACTIVE state.
			$(".arrow").addClass('active');
			$(this).siblings('.arrow.active').attr('src','arrow-up.png'); // change the image src of the new active image to have an active state.
*/
			$(this).parent().next(".sub_nav3").slideToggle();
			return false;
		}
	});
});

