function addToBasket( strFormName )
{
    if( findObject('carrito') != null )
    {
        clipping(strFormName);
    }
    var objForm = eval( 'document.' + strFormName );
    objForm.submit();
}

var tiempo;
var alto=296;
var izquierda=128;
var abajo=0;
var arriba=0;

function clipping(frmNombre)
{
	if( document.all )
	{
		abajo  = 0;
		arriba = 0;
		window.focus();
		clearTimeout(tiempo);
		document.all.boton.style.visibility = 'visible';
		xmouse = event.x;
		ymouse = event.y;
		document.all.boton.style.pixelLeft = xmouse - 70 + document.body.scrollLeft;
		document.all.boton.style.pixelTop  = ymouse - 10 + document.body.scrollTop;

        Mover( frmNombre );
	}
	else
	{
        Blinkar();
	}
}

function Mover( frmNombre )
{
	posIzqui = document.all.boton.style.pixelLeft;
	posAlto  = document.all.boton.style.pixelTop;
	if( posIzqui >= izquierda )
	{
		if ( posAlto > 700 )
        {
            document.all.boton.style.pixelLeft = document.all.boton.style.pixelLeft - 1;
        }
		else if(posAlto>500&&posAlto<700)
		{
			document.all.boton.style.pixelLeft = document.all.boton.style.pixelLeft - 5;
		}
		else if( posAlto > 300 && posAlto < 500 )
		{
			document.all.boton.style.pixelLeft = document.all.boton.style.pixelLeft - 10;
		}
		else
		{
			document.all.boton.style.pixelLeft= document.all.boton.style.pixelLeft - 20;
		}

		if( posAlto > alto )
		{
            arriba = 1;
		}
		else
		{
			abajo = 1;
		}
		if( abajo != 1 )
		{
            document.all.boton.style.pixelTop = document.all.boton.style.pixelTop - 8;
            arriba = 1;
		}
		if( arriba!=1 )
		{
            document.all.boton.style.pixelTop = document.all.boton.style.pixelTop + 8;
            abajo = 1;
		}

		tiempo = setTimeout ("Mover('"+frmNombre+"')", 1);
	}
	else
	{
        clearTimeout(tiempo);
		abajo  = 0;
		arriba = 0;
		document.all.boton.style.visibility = 'hidden';
		Blinkar();
	}
}

function MM_openBrWindow(theURL,winName,features) { //v2.0
  window.open(theURL,winName,features);
}