Magento – Configurable swatches is not functionally working in Magento 1.9. Still asking “Please select items”

swatches

In my theme (bought from themeforest) Configurable swatches is integrated technically but not working functionaly. I can see the swatches in my Product page but when I click on them upon add to cart its showing error "Please select item". When I disable the Configurable swatches then traditional drop-down field is come up and its working.

So I wanted to know why configurable watches is not working? Googled a lot but no answer. Please guys help me in that.

This is the link : https://www.myshopingkart.com/clothing/men/haute-denim-navy-blue-main.html

Configurable Swatches

This the error when I click on the swathces..

Configurable Swatches-error

Best Answer

You have problems with Javascript:

$('.btn-cart-single').bind("click",function(){  
        re = 1;
        proId = $("#proId").val();
        curQty = $('#qty').val();
        minQty = $('#min_qty_stock').val();
        maxQty = $('#max_qty_stock').val();
        qtyStock = $('#qty_stock').val();
        qtyStock_1 = $('#qty_stock').val();
        if ( manage_stock == 0 ){
            qtyStock = maxQty + 1;
        }
        if( minQty==''&&maxQty==''&&qtyStock=='' ){
            alert('Please, select item');
            return false;
        }....

When you try to test in console ()

        minQty = jQuery('#min_qty_stock').val();
        maxQty = jQuery('#max_qty_stock').val();
        qtyStock = jQuery('#qty_stock').val();

The 3 vars show empty "" Try to check when the elements #min_qty_stock, #max_qty_stock, #qty_stock is filled

<span class="quantity-box">

                    <input type="text" name="qty" id="qty" maxlength="12" value="1" title="Qty" class="quantity-input qty">                     
                    <input type="hidden" id="min_qty_stock" name="min_qty_stock" value="">                      
                    <input type="hidden" id="max_qty_stock" name="max_qty_stock" value="">
                    <input type="hidden" id="qty_stock" name="qty_stock" value="">
                    <input type="button" class="quantity-controls quantity-plus" onclick="$('qty').value=Number($('qty').value)+1" value="">    
                    <input type="button" class="quantity-controls quantity-minus" onclick="if(Number($('qty').value)>1){$('qty').value=Number($('qty').value)-1;}" value="">                    
                </span>