This example uses an image on your page (which may be located anywhere) to position the menus relatively to its position. A sample function (the same like the one in the Non-permanent menus example) is used (look at "s_arrays.js") to get the X and Y position of the image, which is named "getStart" (the image is in the top left corner of the red table).Two additional functions are used to handle the resize event and reposition the permanent menus. Quick instructions: 1) Unlike the basic rule, you have to put the link to the "s_loader.js" after the image in the source of the document. But be sure that it is direct child of the BODY (e.g. it is not nested in any other element's tag except the BODY tag). 2) At the end of "s_arrays.js" you will find an explanation how to specify, which menus should be repositioned onresize.
NOTE: This example will not work correctly in IE4.x on Macintosh. This browser does not support correctly the "offsetParent" property and thus does not allow us to find the position of an element correctly on all pages (if the element is nested in some tables, for instance). The best way to find out whether it will work on your pages is to test them in IE4.x on Macintosh. |
|