jQuery button click to hide a div -
i have <div>
hidden through jquery inital when page loads. have button, in on click event <div>
gets visible. want <div>
hidden on button click event also. have event on button click binding grid in asp.net.
following code have tried in #dinner
div , #bnextweek
button.
$(document).ready(function () { $('#dinner').hide(); $('#<%=bnextweek.clientid%>').live('click', function (e) { $('#dinner').hide(); }); });
try this
$('#'+<%=bnextweek.clientid%>).live('click', function (e) { $('#dinner').hide(); });
or can try with
$('#'+<%=bnextweek.clientid%>).live('click', function (e) { $('#dinner').css('display','none'); });
Comments
Post a Comment