DHTML Lab: HierMenus CENTRAL: Version 5 Setup - Step 5
V5 Setup Instructions
Step 5 of 6
By now, you should have created your external array file (step 4), customized the loader script (step 2), added the dummy function declarations to your HTML page (step 1), and optionally added page specific parameters to your page (step 3). Your page now requires one final script that will retrieve the loader file, which will in turn load the arrays and HierMenus script and launch the program. Include the following script somewhere in your HTML page, after the page specific parameters, if you've included them. Since the script writes new elements into your HTML page, be sure that you place the script somewhere outside your page's content (i.e., avoid placing this script between paragraph tags, or table tags, etc.). Since the script can go anywhere, we recommend placing it near the end of the page; right before the closing BODY tag. This way, the loading of your page content will not be delayed by the loading of the HierMenus script.
Note that in cross-frames implementations, this script should be placed in your
navigation page, not your actual content pages; since you want the scripts to only be loaded
once for your frameset and not with each new page load (and because that's the way HierMenus
The SRC attribute should point to the correct location for the HM_Loader.js script. In the example above, HM_Loader.js is in the same sub-directory as your page. If you keep your external scripts in a special directory, make sure the SRC attribute is modified accordingly. For example, if you created a hiermenus directory as we discussed back in step2, then you would modify the above code snippet as follows:
Remember that HM_Loader.js is the file you configured in step 2.
If all of your top-level menus are set to be permanently visible, then congratulations: you're done! You are now ready to test your completed page.
If you created some top-level menus that you need to appear when existing page links are clicked or rolled over with the mouse, then proceed to the next step to finish your HierMenus setup.
Produced by Peter Belesis and
Created: April 22, 2003
Revised: August 28, 2003