Advertisement
Guest User

balexandre

a guest
Feb 11th, 2009
363
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
HTML 2.11 KB | None | 0 0
  1. <%@ Page Language="C#" AutoEventWireup="true" %>
  2.  
  3. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  4.  
  5. <script runat="server">
  6.  
  7.     protected void btnDeleteEvent_Click(object sender, EventArgs e)
  8.     {
  9.         // Do Something
  10.     }
  11.    
  12. </script>
  13.  
  14. <html xmlns="http://www.w3.org/1999/xhtml">
  15. <head id="Head1" runat="server">
  16.     <title>jQuery UI Droppable - Visual feedback</title>
  17.     <link href="_assets/jquery/theme/ui.all.css" rel="stylesheet" type="text/css" />
  18.  
  19.     <script src="_assets/jquery/jquery-1.3.1.js" type="text/javascript"></script>
  20.  
  21.     <script src="_assets/jquery/jquery.ui.all.js" type="text/javascript"></script>
  22.  
  23.     <script type="text/javascript" language="javascript">
  24.  
  25.         $(document).ready(function() {
  26.  
  27.             $("#dialog").dialog({
  28.                 autoOpen: false,
  29.                 height: 140,
  30.                 modal: true,
  31.                 overlay: {
  32.                     backgroundColor: '#000',
  33.                     opacity: 0.5
  34.                 },
  35.                 buttons: {
  36.                     'Delete all items in recycle bin': function() {
  37.                         __doPostBack('btnDeleteEvent', '');
  38.                     },
  39.                     Cancel: function() {
  40.                         $(this).dialog('close');
  41.                     }
  42.                 }
  43.             });
  44.         });
  45.        
  46.     </script>
  47.  
  48. </head>
  49. <body>
  50.     <form id="form1" runat="server">
  51.         <div id="dialog" title="Empty the recycle bin?">
  52.             <p>
  53.                 <span class="ui-icon ui-icon-alert" style="float: left; margin: 0 7px 20px 0;"></span>
  54.                 These items will be permanently deleted and cannot be recovered. Are you sure?</p>
  55.         </div>
  56.         <input type="button" value="Delete Event" onclick="$('#dialog').dialog('open');" />
  57.         <!-- Let's hide using Text="" the linkButton so we can access it's PostBack in the javascript -->
  58.         <asp:LinkButton ID="btnDeleteEvent" runat="server" Text=""
  59.            onclick="btnDeleteEvent_Click" />
  60.     </form>
  61. </body>
  62. </html>
  63.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement