Saturday, 24 August 2013

How to show remote html in ExtJs Window?

How to show remote html in ExtJs Window?

I want to show remote html file into ExtJs Window. I do:
var global_iframe_id = 0;
Ext.ux.IFrameComponent = Ext.extend(Ext.BoxComponent, {
onRender : function(ct, position) {
global_iframe_id += 1;
this.el = ct.createChild({tag: 'iframe', id: 'iframe-'+
global_iframe_id, frameBorder: 0, src: this.url});
}
});
var infoWin = new Ext.Window({
id: 'infoWin',
layout: 'fit',
title:'Ñïðàâêà',
autoScroll:false,
width:window.innerWidth*0.9,
height:window.innerHeight*0.9,
items: [
new Ext.Panel({
layout:'fit',
items: [ new Ext.ux.IFrameComponent({
url:url_servlet+'/Info.html' }) ]
})
]
});
And its work fine. But when i close window and open it again i get error:
TypeError: this.manager is undefined
Maybe i chose wrong way to show html file?

No comments:

Post a Comment