iGuest 3 Report post Posted September 16, 2007 Hi. Recently I've been working on a slightly new design of my website, that includes a new menu-oriented menu system, because I was running out of room in the navigation bar. How the system works, is you put the mouse over a link, and a menu drops down with all the links in that category.Most of this is working perfectly. I can get the menu to popup and go away, and it appears perfectly. The one thing wrong with it is I can't get it to appear in the right place. Every link in the navigation bar is in it's own td, and all tds have a unique id (navtd1, navtd2, etc.).How can I get the position of the td, when it isn't absolute? I had a look through a JavaScript reference pdf, and there were a few functions like pixelLeft, pixelRight that looked promising, but they didn't work, and were only for IE anyway.Does anyone know how to get the position? Share this post Link to post Share on other sites
Sten 0 Report post Posted September 16, 2007 well theres always just making them absolute? thats probably not gonna work but if it was dumb me that would be the first thing id do, lol. Share this post Link to post Share on other sites
TavoxPeru 0 Report post Posted September 17, 2007 To determine the mouse event location in the coordinate plane of the entire document, you can use the pageX and pageY properties of the Netscape event object. For IE, you can use the clientX and clientY properties in conjunction with the scrollLeft, scrollTop, clientLeft and clientTop properties.Take a look to the following topic: Get Mouse Position to get some more information and check out the getPageEventCoords() and the getPositionedEventCoords() functions in my post that i think that can help you.getPageEventCoords functionBest regards, Share this post Link to post Share on other sites
iGuest 3 Report post Posted September 17, 2007 (edited) Have you seen the menus at this site yet?Pure CSS, no javascript required, cross-browser, drop-down, fly-out, what ever suits your fancy. Edited September 17, 2007 by jlhaslip (see edit history) Share this post Link to post Share on other sites
Sten 0 Report post Posted September 18, 2007 that css play site is nice, lots of good stuff on that site, i reckon habble needs this one for what he needs, though i think hes just using text links, not sure Share this post Link to post Share on other sites
TavoxPeru 0 Report post Posted September 18, 2007 I agree with jlhaslip and Sten the cssplay website is an amazing website with lots of good stuf and examples, i forgot it in my previous post. The drop-down using images and text that Sten mention is very cute, maybe i will use it for a new project that i just start. Best regards, Share this post Link to post Share on other sites