function showPicture(cURL, nWidth, nHeight) {
  return window.open(cURL,'','toolbar=no, location=no,scrollbars=no, status=no, width='+ (nWidth + 40) +', height='+ (nHeight + 40))
}

function showPhotogallery(cID) {
	document.getElementById('divContent').style.height = '230px';
	document.getElementById('remoexGallery').style.display = 'block';
	var so = new SWFObject("/flash/gallery.swf?articleID=" + cID, "remoexFlashGallery", "100%", "100%", "8", "#FFFFFF");
	so.write("remoexGallery");
}

function addToBasket(oHref, cInputAmountID) {
	window.location = oHref + '&amount=' + window.document.getElementById(cInputAmountID).value;
	return false;
}

function showSubMenu(oThis) {
	if (oPrevSelectedMenu) {
		oPrevSelectedMenu.className = oPrevSelectedMenu.className.replace(' displaySubMenu', '');
	};
	if (oThis) {
		oThis.className = oThis.className + ' displaySubMenu';
		oPrevSelectedMenu = oThis;
	};
}

function setCss(lChecked, theClass, theStyle, theValue) {
   var CSSRules;

   if (!lChecked) {
	 theValue = '';
   }

   if (document.all) {
     CSSRules = 'rules'
   } else if (document.getElementById) {
     CSSRules = 'cssRules'
   }

   for (var i = 0; i < document.styleSheets[2][CSSRules].length; i++) {
     if (document.styleSheets[2][CSSRules][i].selectorText == theClass) {
       document.styleSheets[2][CSSRules][i].style[theStyle] = theValue;
     }
   }
}

function getDocumentHeight() {
  var myHeight = 0;
  if( typeof( window.innerHeight ) == 'number' ) {
    //Non-IE
    myHeight = window.innerHeight;
  } else if( document.documentElement &&
      ( document.documentElement.clientHeight ) ) {
    //IE 6+ in 'standards compliant mode'
    myHeight = document.documentElement.clientHeight;
  } else if( document.body && ( document.body.clientHeight ) ) {
    //IE 4 compatible
    myHeight = document.body.clientHeight;
  }
  return myHeight;
}

function getDocumentWidth() {
  var myWidth = 0;
  if( typeof( window.innerWidth ) == 'number' ) {
    //Non-IE
    myWidth = window.innerWidth;
  } else if( document.documentElement &&
      ( document.documentElement.clientWidth ) ) {
    //IE 6+ in 'standards compliant mode'
    myWidth = document.documentElement.clientWidth;
  } else if( document.body && ( document.body.clientWidth ) ) {
    //IE 4 compatible
    myWidth = document.body.clientWidth;
  }
  return myWidth;
}