jquery - Not performing yes click event -
so what's supposed happen when user clicks yes answer supposed id of img , perform tasks don't know if should putting id onto link instead of image main part of question not doing steps of yes click function.
i using same plugin page. http://webstuffshare.com/demo/jconfirmaction/index.html , using plugin default usage
<td> <a class="ask" href="#"> <img id="2" class="delete" border="0" title="" alt="" src="images/trash.png"> </a> <div class="question" style="opacity: 1;"> sure ? <br> <span class="yes">yes</span> <span class="cancel">cancel</span> </div> </td> $('.ask').jconfirmaction(); $('.yes').bind('click', function(){ var userid = $(this).parent.attr('id'); var datastring = 'userid=' + userid + '&deleteuser=true'; $.ajax({ type: "post", url: "processes/template.php", data: datastring, }); $(this).parents("tr").eq(0).hide(); });
you don't have class of yes
bind click to.
edit: (post addition of generated code)
try putting id in <div class="question" style="opacity: 1;">
if can't add td , change var userid = $(this).parents('td').attr('id')
;
Comments
Post a Comment