After setting up a good environment, we can use ExtJS to develop.
First, copy the relevant ExtJS files in the project, such as:
Note: It is not necessary to import all the entire EXT development package, so it is easy to cause eclipse to die because eclipse will automatically detect the legality of JS and consume a lot of detection time, CPU and memory. Usually the common development only needs to use the \extjs-4. 2. 1\Resources File package , \extjs-4. 2. 1\bootstrap.js, \extjs-4. 2. 1\ext-all.js These two resources can be, need to import \extjs-4 culture. 2. 1\locale\ext-lang-zh_cn.js on it,
Such as:
Second, edit the HTML-related code:
Note: The above reference JS file order must be:
First reference bootstrap.js//is the base class for all JS
Re-reference Ext-all.js
Third, editor Helloword.js
/* Ext.onready (function () { Ext.Msg.alert ("Hello word!");}) */ Ext.onready (function() { Ext.MessageBox.alert ("Hello World", "Hello world!")});
Operation, the effect is as follows:
Attached: processing in JS edit after the run garbled
See also: http://www.cnblogs.com/maowang1991/archive/2013/02/05/2893155.html
Extjs-4.2.1 (i)--Edit Hello Word