<!--
function paint(what,color,bgColor){
  what.style.color=color;
  what.style.backgroundColor=bgColor;
}

function openPopupWindowWithBar(url,name,properties){
	printingpage =  window.open(url, name, properties);
}

function openWindow(windowUrl, windowName, windowWidth, windowHeight, resizable){
	newWindow = window.open(windowUrl,windowName, "screenX=10,screenY=10,top=100,left=100,width="+windowWidth+",height="+windowHeight+",scrollbars=yes,resizable="+resizable);
	newWindow.focus();
}


function popWindow(windowUrl,windowName,windowWidth,windowHeight,resizable){
    var winl = (screen.width-windowWidth)/2;
    var wint = (screen.height-windowHeight)/2;
    newWindow = window.open(windowUrl,windowName, "screenX=10,screenY=10,top="+wint+",left="+winl+",width="+windowWidth+",height="+windowHeight+",scrollbars=yes,resizable="+resizable);
	newWindow.focus();
}



function langChanged(query){
	newlang=document.langform.lang.options[document.langform.lang.selectedIndex].value;
	if(newlang != null && newlang.length>0)
         document.location.href = query+"&lang="+newlang;
}  

function set(What,Value) {
//alert(What + '\n' + Value);
    if (document.layers && document.layers[What] != null){
		// document.layers[What].visibility = Value;
    //if (document.layers){
	    if(Value == 'visible')
	        document.layers[What].visibility = 'show';
	    else
	    	document.layers[What].visibility = 'hide';
		
		//document.layers[What].visibility = Value;

    }else if (document.all) 
		eval('document.all.'+What+'.style.visibility ="'+ Value+'"');
	else if (document.getElementById){
		var obj = document.getElementById(What);
		obj.style.visibility=Value;
	}
} 


/*
Highlight Image Script II- 
© Dynamic Drive (www.dynamicdrive.com)
For full source code, usage terms, and 100's more DHTML scripts, visit http://dynamicdrive.com
*/

function borderit(which,color){
//if IE 4+ or NS 6+
if (document.all||document.getElementById){
which.style.borderColor=color
}
}


/***********************************************
* Tab Content script- © Dynamic Drive DHTML code library (www.dynamicdrive.com)
* This notice MUST stay intact for legal use
* Visit Dynamic Drive at http://www.dynamicdrive.com/ for full source code
***********************************************/

//Set tab to intially be selected when page loads:
//[which tab (1=first tab), ID of tab content to display]:
var initialtab=[1, "sc1","link1", "link2"]

////////Stop editting////////////////

function cascadedstyle(el, cssproperty, csspropertyNS){
if (el.currentStyle)
return el.currentStyle[cssproperty]
else if (window.getComputedStyle){
var elstyle=window.getComputedStyle(el, "")
return elstyle.getPropertyValue(csspropertyNS)
}
}

var previoustab=""

function expandcontent(cid, link1, link2){
if (document.getElementById){
if (previoustab!="")
document.getElementById(previoustab).style.display="none"
document.getElementById(cid).style.display="block"
document.getElementById(link1).style.display="none"
document.getElementById(link2).style.display="block"
previoustab=cid
return false
}
else
return true
}


function do_onload(){
expandcontent(initialtab[1], initialtab[2],initialtab[3])
}


      function submitForm(brand){
		 document.productsSearchForm.searchBrand.value=brand;
		 document.productsSearchForm.submit();
      }	   


	  function scale()
	  {
		  var img = this.getElementsByTagName('img')[0];	 

		  img.src = img.smallSrc;

		  if (aPicCheck[0] == "new") {
			  aPicCheck[0] = img;
		  }
		  else if (aPicCheck[0] != img) {
			  aPicCheck[1] = img;
			  aPicCheck[0].setAttribute('width', aPicCheck[0].smallWidth);
			  aPicCheck[0].setAttribute('height', aPicCheck[0].smallHeight);
			  aPicCheck[0].src = aPicCheck[0].smallSrc;
			  window.clearInterval(interval);
			  aPicCheck[0].state = 'small';
		  }

		  if (! img.preloaded)
		  {
			  img.preloaded = new Image();
			  img.preloaded.src = img.largeSrc;
		  }

		  var interval = window.setInterval(scaleStep, 10);
		  return false;

		  function scaleStep()
		  {

			  var step = 10;
			  var width = parseInt(img.getAttribute('width'));
			  var height = parseInt(img.getAttribute('height'));

			  if (img.state == 'small')
			  {
				  width += step;
				  height += Math.floor(step * img.ratio);

				  img.setAttribute('width', width);
				  img.setAttribute('height', height);

				  if (width > img.largeWidth - step)
				  {
					  img.setAttribute('width', img.largeWidth);
					  img.setAttribute('height', img.largeHeight);
					  window.clearInterval(interval);
					  img.state = 'large';
					  aPicCheck[0] = img;
				  }
			  }
			  else
			  {
				  width -= step;
				  height -= Math.floor(step * img.ratio);

				  img.setAttribute('width', width);
				  img.setAttribute('height', height);

				  if (width < img.smallWidth + step)
				  {
					  img.setAttribute('width', img.smallWidth);
					  img.setAttribute('height', img.smallHeight);
					  img.src = img.smallSrc;
					  window.clearInterval(interval);
					  img.state = 'small';
				  }//if
			  }//else
		  }//scale step			
	  }//scale


	  function setValue(xx){
						 document.hiddenForm.cityAreaValue.value=xx;
 }
	  //nop/;


//-->


