View Full Version : Question About Offsetting

08-26-2009, 08:59 PM
1) Script Title: anylinkmenu

2) Script URL (on DD): http://www.dynamicdrive.com/dynamicindex1/dropmenuindex.htm

3) Describe problem:

One thing I'd like to change about this script is that, when you hover over the link, the menu pops up IMMMEDIATELY to the right (using the rev="lr") -- I'd like to change that, offset it a bit. It almost covers the word. How would I do that?

I've tried several commands in the anylinkmenu.css but none seem to have any effect.

Any suggestions?



08-27-2009, 04:27 AM
Try finding the below line inside anylinkmenu.js, and add to it the code in red:

var posx=menu.anchorobj._offsets.left + (menu.orientation=="lr"? this.dimensions.anchorw+5 : 0) //base x pos

Don't increase the offset by too much, or the sub menu may be closed before the mouse is quick enough to move over on top of it.

08-27-2009, 04:42 PM

That's much better. I increased it by +20 and it's much better. The trouble was, when attached to a list-down menu (i.e., the links go down the page), if one is shorter than the others, it covers those links. I know I can solve this with images, but they don't match up with the rest of my list.

But this helps. Thanks again!