天天看点

ext框架导入

应用extjs需要在页面中引入extjs的样式及extjs库文件,样式文件为resources/css/ext-all.css,extjs的js库文件主要包含两个,adapter/ext/ext-base.js及ext-all.js,其中ext-base.js表示框架基础库,ext-all.js是extjs的核心库。adapter表示适配器,也就是说可以有多种适配器,因此,可以把adapter/ext/ext-base.js换成adapter/jquery/ext-jquery-adapter.js,或adapter/prototype/ext-prototype-adapter.js等。

  因此,要使用ExtJS框架的页面中一般包括下面几句:

<link rel="stylesheet" type="text/css" href="../extjs/css/ext-all.css" target="_blank" rel="external nofollow" />

<script type="text/javascript" src="../extjs/ext-base.js"></script>

<script type="text/javascript" src="../extjs/ext-all.js"></script>

下面是我做的例子

[img]http://dl.iteye.com/upload/attachment/228635/d90248a3-7ab7-3d08-b66d-10c8b9eb49f2.jpg[/img]

test1.html页面

[img]http://dl.iteye.com/upload/attachment/228637/79972bcd-dd70-3778-afd4-810ee87d6a58.jpg[/img]

运行页面

[img]http://dl.iteye.com/upload/attachment/228640/518de8e5-e5ff-3aef-9bc5-57430d7acfb2.jpg[/img]

extjs基本框架导入成功- -