Click here to Skip to main content
15,909,466 members
Please Sign up or sign in to vote.
4.00/5 (1 vote)
See more:
XML
$("#customers").append('<tr><td>'+tabelData[i].bomId+'</td><td>'+tabelData[i].F_A_Name+'</td><td>'+tabelData[i].levelNo+'</td><td>'+tabelData[i].itemCode+'</td><td>'+tabelData[i].itemName+'</td><td ><a  href="#" class="clicking" ">'+tabelData[i].assIndication+'</a></td><td>'+tabelData[i].reqNumber+'</td></tr>');



C#
<script>
$(document).ready(function(){
$('.clicking').click(function(){
alert("came");
});
});

</script>



Thanks in advance.

Actually i need to fetch a url by using class selector,but this code is not working.
Please any one can help me.
Posted
Updated 17-Dec-13 0:39am
v2
Comments
thatraja 17-Dec-13 6:19am    
What's the error? Check Browser's Developer-Tools or firebug
Er. Tushar Srivastava 17-Dec-13 9:53am    
please can you reformat the code... it is not simple for everyone to look at the code in this way.. Use tabs and spacing to make the code look more readable. Also, I am seeing you used the word "tabel" instead of "table". Is is surely correct?
srkrishnan0509 19-Dec-13 23:38pm    
thank you, tabel is my variable name,it will not stop my program execution.

1 solution

For dynamic bindings you have to use on method.

Try is as below.

XML
<script>
$(document).ready(function(){
$('.clicking').off('click').on('click',function(){
alert("came");
});
});

</script>


For more info : on
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900