<div style="display: none" id="toggler">
[FCK IMPLEMENTATION... ->create()]
</div>
Within this case Firefox won't initialize the texarea. Changing the div to a display: block will display the editor itself. The embedded textarea doesn't receive any input and an textarea access via a editor function results in
Error: uncaught exception: [Exception... "Component returned failure code: 0x80070057 (NS_ERROR_ILLEGAL_VALUE) [nsISelection.getRangeAt]" nsresult: "0x80070057 (NS_ERROR_ILLEGAL_VALUE)" location: "JS frame :: http://cms.copernicus-journals.net/edit ... gecko_2.js :: anonymous :: line 24" data: no]
Is this a known problem (didn't find any corresponding bug message) and is any workaround available?
Thanks,
Stefan.
Tue, 04/18/2006 - 05:15
#1
RE: conflict with a css[display: none] contai
the problem is not there in ie6.
Interesting to note is that if the page is fully loaded at first with display:box and then bij klikking on a link javascrip: element.style.disply = "none";
it does work.
So it needs to be fully loaded first.
well hope this helps somewhat. I can not find it. quickly
RE: conflict with a css[display: none] contai
A page with several editor textarea's, in divs with display set to 'none', wouldn't completely load in firefox, or gives troubles when turning the display on.
The answer is already provided 'why?'. The page should be rendered completely before hiding anything. However in another forum subject the onload event in the body tag can cause a conflict with the editors. So rendering, and then setting display, isn't very nice to see when the page is loading, but can also disable editor functions.
You can't use visibility, because it sets the open spaces occupied by the editor windows. Tried it with several added css attributes, and it is possible when you keep the position absolute. However that entails adjusting the position of all other elements in the page when the display is toggled. Else it would position itself on top of everything around the editor.
However, you can set the wrapper's height to '0px' and overflow to 'hidden'. A simple function can toggle height to 'auto'.
Works in FF and IE, without any rendering problems or dirty looking page loads.