function basket(basketAction,dest,product,motiv,amount){
    //var field = window.document.forms[form].elements['prod['+product+']['+motiv+']'];
    field = document.getElementById(dest);
    //alert( field.value );
    var currVal = parseInt(field.value);
    var amount = parseInt(amount);
    if ( !currVal )
        currVal = 0;
    if ( !amount )
        amount = 0;
    if ( basketAction == "add" ){
        newVal = currVal + amount;
    }else{
        newVal = currVal - amount;
    }
    if ( newVal < 0 )
        newVal = 0;

    field.value = newVal;
}

function checkMultiplier(product,vpe){
    var rest = product.value%vpe;
    if ( parseInt(rest) > 0)
        product.value = 0;
}
