get all checked CheckBox whose id start with "email_"
<script src="//ajax.googleapis.com/ajax/libs/jquery/1.8.3/jquery.min.js">
</script>
<script>
$(document).ready(function () {
$("button").click(function () {
$('input[id^="email_"]:checked').each(function () {
alert($(this).attr('id'));
});
alert($(this).attr('id'));
});
});
});
</script>
----- This should be in header portion of a page And As you see this is done by the Jquery :)

0 comments:
Post a Comment