I\'m having a hard time with getting the value of my dynamically appended textboxes. I\'m using the $.each function to iterate all of the textboxes according to
You can just use the item parameter:
$('#save_grade_button').click(function (){
$('input[type=text]').each(function(i, item) {
var grade = $(item).val();
alert(grade);
});
});
OR with @Adil's answer combined:
$('#save_grade_button').click(function (){
$('[id^=student_grde_G]').each(function(i, item) {
var grade = $(item).val();
alert(grade);
});
});