1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
| <!DOCTYPE html>
| <html>
| <head>
| <meta charset="UTF-8">
| <title>Toolbar and Buttons - jQuery EasyUI Demo</title>
| <link rel="stylesheet" type="text/css" href="../../themes/default/easyui.css">
| <link rel="stylesheet" type="text/css" href="../../themes/icon.css">
| <link rel="stylesheet" type="text/css" href="../demo.css">
| <script type="text/javascript" src="../../jquery.min.js"></script>
| <script type="text/javascript" src="../../jquery.easyui.min.js"></script>
| </head>
| <body>
| <h2>Toolbar and Buttons</h2>
| <p>The toolbar and buttons can be added to dialog.</p>
| <div style="margin:20px 0;">
| <a href="javascript:void(0)" class="easyui-linkbutton" onclick="$('#dlg').dialog('open')">Open</a>
| <a href="javascript:void(0)" class="easyui-linkbutton" onclick="$('#dlg').dialog('close')">Close</a>
| </div>
| <div id="dlg" class="easyui-dialog" title="Toolbar and Buttons" style="width:400px;height:200px;padding:10px"
| data-options="
| iconCls: 'icon-save',
| toolbar: [{
| text:'Add',
| iconCls:'icon-add',
| handler:function(){
| alert('add')
| }
| },'-',{
| text:'Save',
| iconCls:'icon-save',
| handler:function(){
| alert('save')
| }
| }],
| buttons: [{
| text:'Ok',
| iconCls:'icon-ok',
| handler:function(){
| alert('ok');
| }
| },{
| text:'Cancel',
| handler:function(){
| alert('cancel');;
| }
| }]
| ">
| The dialog content.
| </div>
|
| </body>
| </html>
|
|