I have the following input
<input type="checkbox" name="cupon_check" class="cupon_check" attr-num-doc="D00001" attr-sub-tipo="2" value="12848">
and I'm trying to get the vator of 'attr-sub-type in the following way:
$(".cupones_bienvenida_costarica").find(".cupon_check[attr-num-doc='" + nombre_cupon + "']:checked").each(function(index,value){
console.log("CUPONES BIENVENIDA");
console.log($(this).data("sub-tipo"));
});
I do it in that way since I must get that value from several input checkboxes that are selected. but it does not work for me.
Thank you very much in advance