Chapter 14: The Power of Ext JS: What Else Can You Do ?
So much to work with
Form widgets
DateField
xtype: datefield
TimeField
JAVASCRIPT:
-
{
-
xtype:'timefield',
-
fieldLabel: 'Time',
-
minValue: '9:00 AM',
-
maxValue: '6:00 PM',
-
increment: 30
-
}
NumberField
CheckboxGroups and RadioGroups
HtmlEditor
xtype: 'htmleditor'
Data formatting
Basic string formatting
String.format('<div>{0},{1},{2}</div>','content0','content1','content2')
Formatting dates
The Date object has also been extended to have the format() function
Other formattings
JAVASCRIPT:
-
// To format a number to US currency
-
Ext.util.Format.usMoney(num)
-
-
// To strip tags in a string
-
Ext.util.Format.stripTags(str)
-
-
// Capitalize
-
Ext.util.Format.capitalize(str)
Managing application state
Basic 'state'
Ext.state.Manager.setProvider(new Ext.state.CookieProvider())
How do I get that window
Using the back button in Ext JS applications
Use the History class to handle such cases
Accessing the DOM
Finding DOM elements
Manapulating the DOM
Ext.DomHelper
Working with styles
For individual elements, use the applyStyles() method.
To change the stylesheet of our entire document, use Ext.util.CSS package.
Ext JS for the desktop: Adobe AIR
Ext JS community extensions
DatePickerPlus
PowerWizard
TinyMCE
SwfUploadPanel
ColorPicker
Additional resources
Samples and demos
Ext JS API
http://extjs.com/deploy/dev/docs