A tool to generate simple indented menus easily. Works with all 4+ version browsers.
Usage:1. Register and download the files
Before downloading the program you are requested to register yourself. There is no registration fee. If you register, you are allowed to use the program as a free software, and we will inform you about future upgrades.
You can download the files either in zip or in tgz format.
Strictly speaking you only need the 'simplemenu.js' file from the archive. 'bullet.png' and 'blank.png' are good starting points to create your own indenting images, but the rest are just examples.
2. Include simplemenu.js from the head of your page
Insert the following line into the head of your page:
<script src="simplemenu.js"></script>
You can accept the defaults or assign new values to these variables:
menuclass="menu"CSS style name of the menu lines. The default style "menu" is defined here.
menutarget="contents"
The name of the target frame, where the linked item is displayed.
menubulletimg="bullet.png"
menublankimg="blank.png"
Outline symbols. They are usually the same size and mostly transparent.
Each string in the menu array defines one menu line. One line looks like: "1+Text|Link|Status"
The first character is the outline level. Level 0 is the top level and is not indented Levels 1-9 are indented with one menubulletimg and (level-2) menublankimg.
The second character is the linking mode
| ' ' | no link (rarely used) |
| '+' | frame menutarget (most common) |
| 't' | frame _top |
| 's' | frame_self |
| 'p' | frame _parent |
The substring from character 2 to the first | delimiter is the Text.
Text is the visible part of the menu. It can be a text or an <img ...> tag.
The substring from the first | to the second | delimiter is the Link.
If the user clicks on the menu item this page will be loaded into frame menutarget.
Link can be omitted.
The substring from the second | to the end of the string is the Status
The Status is displayed in the status line when the mouse is over the Link.
Status can be empty, and is meaningless if Link is empty.
Insert the following lines into the body of your page where you want the menu to appear:
<script>
menuwrite();
</script>
Example: (See it working above)
<script>
menu=[
"0+Example",
"1+Shapes|info.html|About shapes",
"2+Circles||Please select color",
"3+Red|redcircle.html|Click to see the red circle",
"3+Green|greencircle.html|Click to see the green circle",
"3+Blue|bluecircle.html|Click to see the blue circle",
"2+Rectangles||Please select color",
"3+Red|redrectangle.html|Click to see the red rectangle",
"3+Green|greenrectangle.html|Click to see the green rectangle",
"3+Blue|bluerectangle.html|Click to see the blue rectangle",
"1+Colors||Select only the colors",
"2+Red|red.html",
"2+Green|green.html",
"2+Blue|blue.html"];
menuwrite();
</script>
A real world example: http://www.propix.hu/mainframe.html
See also the Flicker free outline style menu generator for 5+ browsers. It is even more powerful, and uses the same menu definition table.