Josh, yes, the window-level select problem is one of the most annoying
IE shortcommings.
I didn't like the iframe solution for some reason--I can't remember why,
maybe it was too slow for some pages. Anyway, I use the following class
to temporarily set "visibility: hidden". It is different from "display:
none" in that the element takes up the same amount of space, while
"display: none" collapses the elements.
var SelectToggler = Class.create();
SelectToggler.prototype = {
initialize: function(element) {
if( document.all ) {
element = $(element) || document;
this.visible = true;
this.running = false;
this.selectList = document.getElementsByTagName('select') || [];
}
},
show: function(booleanShow) {
if( document.all && this.visible!=booleanShow && !this.running) {
this.running = true;
for( var i = 0; i<this.selectList.length; i++ ) {
this.selectList[i].style.visibility = booleanShow ? 'visible' :
'hidden';
}
this.visible = booleanShow;
this.running = false;
}
}
};
Josh wrote:
> The site I am creating contains windows that can be dragged around the
> page (think desktop). When one of those windows contains a SELECT
> element, it always overlays all of the other elements on the page.
> This is, of course, a problem with the windowing effect as the select
> box appears above other windows. This is only a problem in IE.
>
> Per my research, the problem is due to SELECT elements being rendered
> by the OS and not the browser itself and means that we cannot set the
> z-index of the element. The most promising solution I found online
> involved using an IFRAME to hide the SELECT element when another window
> floats over the one containing the SELECT.
>
> It seems that this would be a fairly common problem, so I hope that
> there may be a pre-existing solution to the problem or that the library
> already contains handling that I have not found.
>
> Any thoughts? Has anyone encountered this problem before?
>
>
> >
>
>
>
>
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby
on Rails: Spinoffs" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/rubyonrails-spinoffs
-~----------~----~----~----~------~----~------~--~---