Hi, I was practicing some examples , on click of a button a calendar slidesdown dynamically, but whenever I am clicking some content on the calendar its geting posted back and its dissapearing, my code is as follows
<html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" /> <title>JQuery Collapse</title> <script src="jquery-1.3.2.min.js" type="text/javascript"></script> <script type="text/javascript"> $(document).ready(function() { $("#click_here").click(function(event) { //event.preventDefault(); $("#div1").slideToggle(); }); $("#div1 a").click(function(event) { event.preventDefault(); $("#div1").slideUp(); }); }); </script> <style type="text/css"> body { font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 20px; color: #666666; } a{color:#993300; text-decoration:none;} #div1 { width:70%; display: none; padding:5px; border:2px solid #EFEFEF; background-color:#FEFEFE; } #click_here{ padding:5px; border:2px solid #FFEFEF; background-color:#EFEFEF; } </style> </head> <body> <form runat ="server" id="frmTest"> <input type="button" id="click_here" value="Click Here"> <div id="div1"> <a href="#" class="close">[x]</a> <p> <asp:Calendar ID="cl1" runat="server"></asp:Calendar> </div> </form> </body> </html>