View Full Version : [1.1.1][2.0+]ux.ManagedIframe

29 Oct 2007, 6:45 PM
I'd like to introduce an Element extension (basically) for IFrames. It's particularly useful for Iframes used as the body of an Ext.ContentPanel.

More details are available here (http://extjs.com/forum/../learn/Extension:ManagedIframe).

Some features available:

- provides an update method for writing content directly (or via UpdateManager) to IFrames document.
- adds execScript method for 'eval' js source modules directly into the Iframe's window context.
- adds print method to programatically print the iframes contents.

The attached source files are designed to be dropped into the examples/tabs folder of your 1.1.1 distribution, but the ux.ManagedIframe (miframe.js) can be used with any version of Ext 1.1 or higher.

UPDATE: 1/29/2008 RC2 Uploaded for Ext 1.1.1.

31 Oct 2007, 6:00 AM
Sounds pretty interessting. Can you tell me how i can use this in a Tab-Element??


31 Oct 2007, 6:05 AM
Are we talking about 1.1 or 2.0 ?

The TabPanel additions would be about the same as shown here (http://extjs.com/forum/../learn/Extension:ManagedIframe)

31 Oct 2007, 6:08 AM
I'm using 1.1.

I read the instructions but didn't find a way so far to add it to a tab panel. But I#m still a newby to ext. Can you help me?


31 Oct 2007, 6:10 AM
I'll update that document Examples [1.1] in a few minutes.....

Having ~o)...

31 Oct 2007, 6:11 AM

thanks in advance :)

~o) -Break

31 Oct 2007, 10:27 AM
Rather than 'write a book' for a 1.1+ TabPanel demonstration, a sample is now included in the new zip file that you can drop in your examples/tabs folder.

Then run 'itabs.html' for the demo.

Good luck with it.

4 Nov 2007, 10:49 PM
thanks for helping =D>

7 Nov 2007, 6:09 AM
I tried to use the ManagedIFrame in the window of desktop example, but no luck, it said "c.render is not a function" in ext-all-debug.js line 14135. I also tried to add a render function to the ManagedIFrame, but getting some other error. Do you think it is possible to use the managedIframe in the desktop demo?

var iframe = new Ext.ux.ManagedIFrame({autoCreate:{id:'dynamic'},url:'myold.html',scripts:true});
win = desktop.createWindow({
id: 'grid-win',
iconCls: 'icon-grid',
layout: 'fit',
items: iframe

7 Nov 2007, 7:50 AM
@davidchantf - As your post is specific to 2.0, see my thread post here (http://extjs.com/forum/showthread.php?p=83336#post83336).

29 Jan 2008, 4:58 AM
maybe a good idea is put the link for this page in the tutorial, becouse there don't exist the zip of extension

29 Jan 2008, 6:04 AM
@Battisti -- Yes, sorry RC2 has been uploaded on the first post of this thread. (For Ext 1.1.1 only)

30 Jan 2008, 3:21 AM
i use this code to add dinamic my tabs in the tabPanel, its load correct but i can't access nothin in the iframe, i using RC2.

After the iframe is load I can scrol on the page, click in the links but not click in input's or use the scroll of mouse or select a text, some idea? :-?

this is the code who a use to add tabs
function addAba(texto,id,uri){
// localizar a aba
var tabs= Ext.getCmp('tabPanelCentral');

// fun

30 Jan 2008, 3:32 AM

sorry its a problem in my HTML i have on div hover my page :( sorry

but the function to addtab its correct :) and the component is very god

30 Jan 2008, 3:34 AM
The page if i cal under my iframe use EXT, who can i do to don't include the ext in this page and make it use the ext who load out of iframe?

30 Jan 2008, 5:22 AM
@battisti -- Read the 2.0 thread (http://extjs.com/forum/showthread.php?t=16590) thoroughly, it discusses the difficulty/issues with what you want (especially IE).

7 Feb 2008, 10:01 AM
Since the topic of "Load Ext once, and apply it to iframes" has come up many times in the past, check out this post (http://extjs.com/forum/showthread.php?p=120384#post120384) for the Ext 2.0 version of that solution.

That can be adapted for use in 1.1+ also.