Home > Web Front-end > JS Tutorial > body text

When importing extjs and jquery files, use the conflict resolution method_extjs

WBOY
Release: 2016-05-16 17:03:49
Original
1306 people have browsed it

1. When working on a recent project, in the html page, if the jquery file is not imported, it can be saved normally, but after importing the jquery file, it cannot be saved

After debugging, I found that the imported The jquery file conflicts with the existing extjs file (the reason is the conflict of the $ symbol)

There is a conflict between jQuery and ExtJS, but it is ok under the non-IE kernel. It is due to the conflict of the $ symbol. Solved The way is to replace jQuery's $ symbol with something else. The code is as follows:

Copy the code The code is as follows:





When calling on the html page, as follows: (use the jq defined above instead of the $ symbol)
Copy the code The code is as follows:

function a(){
jq("#SARYXX_XM").jSuggest({
url: "../../ftdxxglxt/highchart/jsp/autoFind.jsp" , //The processing page to be sent to
type: "GET",
data: "sary_xm" , //Parameter
autoChange: true
});
}
Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template