I think I'm nearing the completion of my Tab and tabContainer components. That is, unless I get feedback about something I may have missed.
I added a few "content" options to the Tab component:
content.type - set option to use <iframe> or <div> for tab content.
content.innerHTML - set tab <div> content to an HTML string value.
content.url - set tab <iframe> source to a URL value.
content.loadOpt - set option to load or refresh content when the tab is created, or first activated, or each time the tab is selected.
I also updated my Tab Sample page to test the new <div> & content.innerHTML properties, if anyone is interested.
http://www.radile.com/rdweb/temp/tabs.html
My earlier sample page took more time to load because each tab (25 of them) was bound to its own <iframe> page, which hit the server with 25 more requests. This new example loads quickly.
Nathan.
----- Original Message ----
From: Nathan Andelin <nandelin@xxxxxxxxx>
To: Web Enabling the AS400 / iSeries <web400@xxxxxxxxxxxx>
Sent: Thursday, October 2, 2008 1:41:14 AM
Subject: Re: [WEB400] Tabs in HTML Pages
One reason I like to use <iframe> elements for tab content is because you can set their height & width to "100%", and the size of the frame will automatically adjust to the size of their container, whatever that may be. That was one reason for my putting a vertical splitter bar in my sample. It added a temptation to see the effect of resizing left and right panels by dragging one way or the other. Tab content automatically resizes, and the position of horizontal tabs automatically adjust themselves to fit their container. I haven't seen that type of behavior in any other HTML based tab sample, and I wondered if anyone would notice. Oh well, maybe it wasn't that impressive.
Other tab samples I've seen have used HTML <div> tags for tab content, instead of <iframe> tags. I also wondered if anyone would question that? Under my interface an <iframe> is automatically generated when a tab is added to a container. That's been nagging me for a while. It seems that I'll need an interface for <div> based content too. Oh well, back to the drawing board...
Nathan.
As an Amazon Associate we earn from qualifying purchases.