sencha touch 在视图中显示一个html页面

 1 Ext.define('app.view.about.About', {
 2     alternateClassName: 'about',
 3     extend: 'Ext.Container',
 4     xtype: 'about',
 5     config: {
 6         cls: 'info',
 7         scrollable: {
 8             direction: 'vertical',
 9             directionLock: true
10         },
11         url: 'http://www.baidu.com/'
12     }, 
13     initialize: function () {
14         Ext.Ajax.request({
15             url: this.config.url,
16             success: function (rs) {
17                 this.setHtml(rs.responseText);
18             },
19             scope: this
20         });
21     }
22 });

效果图:

不过不能搜索,只能简单的展示而已。

代码来至于oreilly示例

原文地址:https://www.cnblogs.com/mlzs/p/3142540.html