I have several div's with the class .agrRow. In each .agrRow there is an input field with the name agrPrice.
I want to get the value of that field for each instance of .agrRow. I've tried something like:
$(".agrRow").each(function(){
// get price for this field
lp=parseFloat( $("input[type='text'][name='agrPrice']").val() );
});
but that only ever gives me the value of agrPrice in the first instance of .agrRow class.
I'm sure I need to incorporate "this" but I'm not sure how.
What is the correct syntax?