3xtr3m3d
asked on
Jquery button help
Hi
Im trying to create dynamic table which will insert row to end of the table and row contains a jquery button
row adding works fine. but button not working
i guess its because im adding button after document ready.
how to fix this problem?
Im trying to create dynamic table which will insert row to end of the table and row contains a jquery button
row adding works fine. but button not working
i guess its because im adding button after document ready.
how to fix this problem?
ASKER
Hi
Thanks for reply and buttons now working but created button is just a button and is it possible to change created button back to a jquery ui button?
current code is
Thanks for reply and buttons now working but created button is just a button and is it possible to change created button back to a jquery ui button?
current code is
$(document).ready(function() {
$( '.Eb1' ).button({
icons: {
primary: "ui-icon-arrowthick-1-w"
},
text: false
})
.click(function() {
$("#mydiv").append('<table><tr><td>I Am The 1st</td></tr><tr><td><button id="btn">am a button</button></td></tr></table>');
});
$("#btn").live ( "click" , function () {
alert('you pressed me??');
});
});
<div id="mydiv"></div>
<button class="Eb1">add</button>
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
you can try like this :
Open in new window