Image Width and Height bugs found

Having problems with DHTML Menu? There is usually somebody here who knows the answer.
Post Reply
tomistrugar
Beginner
Beginner
Posts: 6
Joined: Wed Apr 23, 2003 7:25 am

Image Width and Height bugs found

Post by tomistrugar »

Dear Milonic

I believe I have finally found the bugs that caused the problem I reported in my post viewtopic.php?t=2573

On the Menu Items Quick Reference Guide it states that:

imageheight has code ref = 37
imagewidth has code ref = 38

This is correctly coded in milonic_src.js


However in mmenudom.js and mmenuns4.js the code refs have been switched. This is bug #1.

Additionally, in mmenudom.js and mmenuns4.js there is a typo:
the code

_Ihgt="";if(_I[38])_Ight=" height="+_I[38];

should read

_Ihgt="";if(_I[38])_Ihgt=" height="+_I[38];

i.e hgt instead of ght. This is bug #2.

Once I switched the code refs around in mmenudom.js and mmenuns4.js and corrected the typo, then my menu correctly coded BOTH the imageheight and the imagewidth.

Keep up the great work.

Tomi
User avatar
Andy
Milonic
Milonic
Posts: 3308
Joined: Sun May 19, 2002 8:23 pm
Location: Menu Developer
Contact:

Post by Andy »

Well well well :D

What a star.

I only wish I could give certain people copies of the commented code, these things would be figured out in no time then.

Well found that man.

Cheers
Andy
User avatar
John
 Team
 Team
Posts: 5967
Joined: Sun May 19, 2002 8:23 pm
Location: Phoenix, AZ
Contact:

Post by John »

Great catch, Tomi. Most appreciated... :D
John
User avatar
Maz
Milonic God
Milonic God
Posts: 1717
Joined: Fri Jun 06, 2003 11:39 pm
Location: San Francisco
Contact:

Post by Maz »

:D Thank you Tomi...
give the man a kiss *

I wonder how many that will fix on my menu,
maz

:evil: Hg=mercury... see I could have told you that, I've been told it will even mess with the precision of the atomic clock
User avatar
Hergio
Milonic God
Milonic God
Posts: 1123
Joined: Wed Jun 12, 2002 7:46 pm
Location: Rochester, NY

Post by Hergio »

Wow very nice catch. I can't believe a typo/bug got past Andy!! You guys do understand this is his one slip up for the year, its not often you'll see something like this, so cherish it! :lol:

I am surprised it did not throw an error, eh Andy?
Dave Hergert
Software Engineer
"Helping to make the menu better, one :?: at a time."
User avatar
Andy
Milonic
Milonic
Posts: 3308
Joined: Sun May 19, 2002 8:23 pm
Location: Menu Developer
Contact:

Post by Andy »

It's one of those bugs that won't generate an error because the variable does get set, it also creates a new (wrong) variable.

The goo variable doesn't get updated with the correct information though.

Very tricky to find enless you are looking for it.

-- Andy
Post Reply