Multiplying field value with retreived value jQuery
<p>I pull product price from another page. Then I multiply it with quantity entered in the quantity input field. The problem is, if I forget to enter quantity value before I pull product price data or if I change the quantity field later, the final total price is not updated. I hope I clearly explained it.</p>

<p>javascript:</p>

<pre><code>$('#AddProduct').click(function() {
    var i = 0;
    var adding = $(+(i++)+'&lt;div class="row'+(i)+'"&gt;&lt;div class="column width50"&gt;&lt;input type="text" id="PRODUCTNAME" name="PRODUCTNAME'+(i)+'" value="" class="width98" /&gt;&lt;input type="hidden" class="PRODUCTID" name="PRODUCTID" /&gt;&lt;input type="hidden" class="UNITPRICE" name="UNITPRICE'+(i)+'" /&gt;&lt;small&gt;Search Products&lt;/small&gt;&lt;/div&gt;&lt;div class="column width20"&gt;&lt;input type="text" class="UNITQUANTITY" name="UNITQUANTITY'+(i)+'" value="" class="width98" /&gt;&lt;small&gt;Quantity&lt;/small&gt;&lt;/div&gt;&lt;div class="column width30"&gt;&lt;span class="prices"&gt;Unit Price:&lt;span class="UNITPRICE"&gt;&lt;/span&gt;&lt;br /&gt;Total Price:&lt;span class="TOTALPRICE"&gt;&lt;/span&gt;&lt;br /&gt;&lt;a href="#" id="RemoveProduct(".row'+(i)+'");"&gt;Remove&lt;/a&gt;&lt;/span&gt;&lt;/div&gt;');    
    $('#OrderProducts').append(adding);

    adding.find("#PRODUCTNAME").autocomplete("orders.cs.asp?Process=ListProducts", {
        selectFirst: false
    }).result(function(event, data, formatted) {
        if (data) {
            adding.find(".UNITPRICE").html(data[1]);
            adding.find(".PRODUCTID").val(data[2]);
            adding.find(".TOTALPRICE").html(data[1] * $('.UNITQUANTITY').val()); 
        }
    });

    return false;
});

$('#RemoveProduct').click(function() {
    $().remove();

    return false;
});
</code></pre>

<p>my html:</p>

<pre><code>        &lt;fieldset&gt;
            &lt;h2&gt;Order Items&lt;/h2&gt;
            &lt;div id="OrderProducts"&gt;
                &lt;a href="#" id="AddProduct"&gt;&lt;img src="icons/add.png" alt="Add" /&gt;&lt;/a&gt;
            &lt;/div&gt;  
        &lt;/fieldset&gt;
</code></pre>

<ul>
<li>edit</li>
</ul>

<p>Now I totaly messed it up. Removing a row is not working anymore as well...</p>
