source: trunk/web/addons/job_monarch/lib/extjs/examples/form/absform.js @ 619

Last change on this file since 619 was 619, checked in by ramonb, 15 years ago

lib/:

  • added new AJAX dependancies: ExtJS, pChart, Lightbox2
File size: 1.4 KB
Line 
1/*
2 * Ext JS Library 2.2.1
3 * Copyright(c) 2006-2009, Ext JS, LLC.
4 * licensing@extjs.com
5 *
6 * http://extjs.com/license
7 */
8
9Ext.onReady(function() {
10    var form = new Ext.form.FormPanel({
11        baseCls: 'x-plain',
12        layout:'absolute',
13        url:'save-form.php',
14        defaultType: 'textfield',
15
16        items: [{
17            x: 0,
18            y: 5,
19            xtype:'label',
20            text: 'Send To:'
21        },{
22            x: 60,
23            y: 0,
24            name: 'to',
25            anchor:'100%'  // anchor width by percentage
26        },{
27            x: 0,
28            y: 35,
29            xtype:'label',
30            text: 'Subject:'
31        },{
32            x: 60,
33            y: 30,
34            name: 'subject',
35            anchor: '100%'  // anchor width by percentage
36        },{
37            x:0,
38            y: 60,
39            xtype: 'textarea',
40            name: 'msg',
41            anchor: '100% 100%'  // anchor width and height
42        }]
43    });
44
45    var window = new Ext.Window({
46        title: 'Resize Me',
47        width: 500,
48        height:300,
49        minWidth: 300,
50        minHeight: 200,
51        layout: 'fit',
52        plain:true,
53        bodyStyle:'padding:5px;',
54        buttonAlign:'center',
55        items: form,
56
57        buttons: [{
58            text: 'Send'
59        },{
60            text: 'Cancel'
61        }]
62    });
63
64    window.show();
65});
Note: See TracBrowser for help on using the repository browser.