<div id=id1> <input class=class1> </div> <div id=id2> <input class=class1> </div>
$(".class1").parent().attr('id')
var pIds=[]; $(".class1").each(function() { pIds.push($(this).attr("id")); });
$(".class1").parent().each(function (i, e) { var id = e.id; alert(id); })
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)