DHTML Menu Builder in HTML Editor

User 364143 Photo


Guest
5,410 posts

OK, I finally broke down and purchased the HTML Editor and Flash Form Builder.

The first thing I noticed is that the DHTML menu does not display in Opera. JavaScript is enabled. Any ideas?

Also, I picked a layout to open and inserted a DHTML menu in the Nav div. Only it doesn't display in the nav div on preview, it displays top 0 left 0. Why?

Another quirk. When the doctype is html 4.01, the line break should be <br> and not <br />. <br /> validates for XHTML only according to the W3C. Why is this not compliant?

Thanks.
CoffeeCup... Yeah, they are the best!
User 355448 Photo


Ambassador
3,144 posts

Tom,

The DHTML menu in the HTML Editor is the same as the stand alone free DHTML menu builder, and it does have a few issues.

You can pull the file from my web site. The address is http://www.roberson-family.com/incl/sitenav2.js

Copy from my file and replace in your file everything below the lines that say:
/***********************************************************************
DO NOT EDIT ANYTHING BELOW THIS LINE - IT WILL BREAK THE SCRIPT !
***********************************************************************/

Then in the top section, find the ten lines with the color codes, and insert a # at the beginning of each of them.

That should make everything work. If not, let me know and we can check deeper into it.
User 364143 Photo


Guest
5,410 posts

Thanks Bill. The changes didn't position the menu to the div but upon further examination I found I can position the menu to where I want using this.

var StartTop=1; // Menu offset x coordinate
var StartLeft=1; // Menu offset y coordinate

So what issues does your code replacement fix?
CoffeeCup... Yeah, they are the best!
User 355448 Photo


Ambassador
3,144 posts

Tom,

The menu without the code replacement will not work with a strict doctype.

There is also some strange behavior with the static menu. The menu will track down the browser, but when you select a drop-down sub-menu, it appears over the top left main menu.

There is a spot in the code where a span can be named, and putting the <span id="themenu"> will allow positioning the menu. I use that on one of my sites to put the menu below the logo area. That bit of code is located at:

var TargetLoc='themenu'; // span id for relative positioning


I don't remember all the other issues that were fixed with the help of someone with javascript skills.

Have something to add? We’d love to hear it!
You must have an account to participate. Please Sign In Here, then join the conversation.