Login | Register   
Twitter
RSS Feed
Download our iPhone app
TODAY'S HEADLINES  |   ARTICLE ARCHIVE  |   FORUMS  |   TIP BANK
Browse DevX
Sign up for e-mail newsletters from DevX


Tip of the Day
Language: Netscape Communicator
Expertise: Beginner
Feb 4, 1999

Using Expandable Outlines in Netscape

Question:
I've written a page that uses expandable outlines using the display property of SPAN objects and it works fine in Internet Explorer 4. However, Netscape does not seem to use this property of SPAN objects. Is there any way to use expanding outlines in Netscape 4?

Answer:
Expandable outlines from Netscape are considerably more complex than they are in DHTML, for a number of reasons. For starters, whereas with Internet Explorer 4.0 every object can accept events, with Netscape this functionality is limited severely to layers, with only a marginal amount of support for DIVs and none, as far as I'm aware of, for SPANs. As a consequence, building a dynamic outline can be well near impossible without the use of Java.

The second limitation you face is that Netscape doesn't support the notion of visibility with such containers, nor does it support the concept of the display: attribute, which can take a hidden value and remove the object from the rendering stream. The reason for this has to do with a choice Netscape made in development some time back, and is now paying for dearly by having to rewrite their rendering engine:

The object model for Netscape Navigator is fundamentally static—once an object is rendered on the page, the render buffer remains fixed. In a few cases, you can actually go into Navigator and write contents into a layer, but only because layers have been defined as having their own architecture separate from the rest of the elements on the page. As a result, about the only way that you might be able to create expanding properties would be to use embedded LAYERS, maintain the outline in a separate data structure, then write or clear an entry when it receives a mouse click.

DevX Pro
 
Comment and Contribute

 

 

 

 

 


(Maximum characters: 1200). You have 1200 characters left.

 

 

Sitemap