DynLayer Functions

There are 2 other functions I need to explain:

The DynLayerTest() Function

The DynLayerTest() function was added only as a debugging function. I really should have included this sooner as it really helps you when you get into creating DHTML Objects. This function will automatically double check your initialization (the id and the nestref parameters) to make sure the layer in fact does exist before defining itself. It does not check when you use IFrame, you're on your own with that.

If you happen to get the initialization wrong, the DynLayerTest() function will show an alert() of what layer in the hierarchy is the problem (<-- this layer cannot be found). This should help you figure out what's wrong with your code. This function is redundant for layers that are initialized by the DynLayerInit() function.

The css() Function

I'm including the css() function in the DynLayer because many of the later lessons in this tutorial are using it. This is more a personal preference than a necessity. Read the Generating Layers lesson for an explanation of this function.

The Dynamic Layer Object API

Home Next Lesson: DynLayer Extensions
copyright 1998 Dan Steinman

Casa de Bender