I'm using jQuery on a JSF application. I have a radiobutton, which has some Ajax rendering when clicked and on success, I'm trying to remove it (for simplicity)
My ajax callback looks as such:
function ajaxOnSuccess(data) {
var getId = data.source.id;
$(getId).remove(); // This won't work
}
console.log($(getId))
is returning [prevObject: n.fn.init[1], context: document, selector: "coverage:j_idt483:0:j_idt487:0:printableNts:select-one-radio:0"]
- so I'm thinking it is not able to find the element?
How can I select the radiobutton?