Ext and js details used in the project, extjs details
1. no replaceAll method is available in js, but replace (regex, "") can be used. The first parameter is a regular expression, and the second parameter is string, eg: str. replace (/\ r \ n/g, "*") means to replace all carriage returns.
2. Press enter in textarea to automatically fill \ r \ n, which can be obtained by js, but no \ r \ n is obtained by the server.
3. how to obtain DOM elements using EXT. getDom (), pay attention to Ext. get (), Ext. getDom (), Ext. getCmp (), Ext. difference in getBody.
4. Implement ctrl enter submission:
Event: function ctlSubmit (event) {if (event. ctrlKey & event. keyCode = 13) {form. submit ()} textare: <textarea name = "co" cols = "50" rows = "10" onKeyDown = "ctlSubmit (event);">
5. Differences between renderTo and contentEl:
RenderTo generally refers to rendering the Panel to a certain place. When I use contentEl, I render a custom label (such as div) to this Panel.
6. Highlight the page, change textarea to panel, and dynamically modify the html attributes of the panel:
Ext. getCmp ("panelId"). body. update ("html code ")
How can I add extjs to a java web project? I use the Apache server eclipse tool.
Copy the ext-base.js, ext-all.js, ext-all.css, and the resource Directory to the project, and then introduce the above files in the page to use extjs, note that the ext-base.js must be before the introduction of the ext-all.js, the relevant files can be searched in the extjs Development Kit
Ext js 40 files to be added to the project
-This debugging and formatted js can be used during debug development.
-Dev is similar to-debug. It is also used for development with more annotations.
Bootstrap. js, in the page can only reference this js, this js will judge whether the current address is localhost, if it is localhost load-dev js if it is a domain name load ext-all.js