Thursday, January 15, 2009

frameset and div element

I just started working on java script to provide some enhancements to the basic PeopleNet application. The requirement is to design a light box to display information about the new features in the application. Application’s main page consists of frames and wanted to add light box over it to mask the entire screen and have the popup with the data. Most of the light boxes are developed such that they add a div element (light box actually) on a body tag, which works fine, but when i was trying to add div element to frameset it does not display the light box.

I was searching around but could not find any information regarding adding a div to the frameset.

1 comment:

Sajjan Sarkar said...

Sorry Mr.K.. No cookie for u here..U cant do it..Framesets dont support DIVs over them.. even by manipulating z-indices u cant do it..my personal opinion is u shudnt be using framesets in the first place.. till the much vaunted XFrames come around, iFrames are a far better option.
Some reason why NOT to use framesets:
* Framing breaks the link between content and a URL, making it difficult to link to or bookmark a particular item of content within the frameset
* The implementation of frames is inconsistent across different browsers
* Visitors arriving from search engines may land on a page intended for display in a frame which has no navigation
* Frames change the behavior of the back button
* Frames usually don't print the way users expect they will
* External links on web pages which use frames may cause other pages to appear in the frameset.
* If the screen resolution or browser window size is too low then each frame will have scroll bars which can look messy and uses up already limited space. Such behaviour typically resulted more from bad site design (fixed layouts instead of fluid layouts), whereby not all frameset features were put into proper use.

This behaviour could be mitigated by:

* disabling scrolling for smaller frames that typically didn't require a scrollbar;
* using fluid design characteristics in target pages instead of fixed designs, so that the content wouldn't cause horizontal scrollbars in the first place.

I had this issue once a couple of years back when I wanted to layer a menu across a sidebar frame. No cookie for me then!

Sorry about the post-dated comments but ur later posts are abt GXT, and in that dude..ur THE man!