-/*!
- * Ext JS Library 3.2.0
- * Copyright(c) 2006-2010 Ext JS, Inc.
- * licensing@extjs.com
- * http://www.extjs.com/license
- */
+Ext.require([
+ 'Ext.form.*',
+ 'Ext.window.Window'
+]);
+
Ext.onReady(function() {
- var form = new Ext.form.FormPanel({
- baseCls: 'x-plain',
- labelWidth: 55,
- url:'save-form.php',
+ var form = Ext.create('Ext.form.Panel', {
+ border: false,
+ fieldDefaults: {
+ labelWidth: 55
+ },
+ url: 'save-form.php',
defaultType: 'textfield',
+ bodyPadding: 5,
items: [{
fieldLabel: 'Send To',
xtype: 'textarea',
hideLabel: true,
name: 'msg',
- anchor: '100% -53' // anchor width by percentage and height by raw adjustment
+ anchor: '100% -47' // anchor width by percentage and height by raw adjustment
}]
});
- var window = new Ext.Window({
+ var win = Ext.create('Ext.window.Window', {
title: 'Resize Me',
width: 500,
height:300,
minWidth: 300,
minHeight: 200,
layout: 'fit',
- plain:true,
- bodyStyle:'padding:5px;',
- buttonAlign:'center',
+ plain: true,
items: form,
buttons: [{
}]
});
- window.show();
+ win.show();
});
\ No newline at end of file