PDA

View Full Version : Basic question on Layouts



SilverTab
6 Apr 2007, 11:35 AM
Ok this is a very basic question (and it might actually sound stupid eh)...

I want to use ext-js for a basic layout (header, collapsible side navigation, and main content)

Now I'm able to do that (and it looks great BTW! kick ass work :) )

My question is, if I want to have multiple links in the side navigation, linking to sections that will open in the main content region, what is the best way to proceed?

My initial idea was to use an i-frame in the main content region and set it's height and width to 100%, then my links in the side navigation would target that iframe... would this be a reasonable way to achieve what I want? Is there a better way to "dynamically" load content in the main content region when a link in the side navigation is clicked?

Any help would be appreciated!

xmrcivicboix
6 Apr 2007, 11:41 AM
on your main content area, you could have a div that serves as your content. Given the id of that div, you could easy use the built AJax load() method to load your content. Further, your content doesn't have to be the entire html page, it could simply be a segment, such as a user input form, a paragraph, etc.. but not the ENTIRE page. :-|

SilverTab
6 Apr 2007, 12:20 PM
Ok gotcha!

I'm familiar with MooTools and prototype ajax's class...Still haven't looked at how ext-js handles it...Does it have some kind of wrapper for YUI or prototype's ajax classes (depending on which adapter I use) or should I use YUI's classes directly?

SilverTab
6 Apr 2007, 12:22 PM
Ok I think i've answered my own question...seems like the class I should be looking into is:
Ext.UpdateManager right?

xmrcivicboix
6 Apr 2007, 12:28 PM
i think so? :-? ... I used UpdateManager for the tabs so I would so. Anyone?

SilverTab
6 Apr 2007, 12:31 PM
OK I got it to work like I wanted :)

Using UpdateManager for simple "get" requests for my html pages (which are only the main content's...content... LOL...i.e. not a full page)

Thanks for your help! :)

xmrcivicboix
6 Apr 2007, 12:33 PM
Hey glad to help. I'm still a noob with EXT myself. :))