Superfish (Navbar): second Navbar under parent
Hi there,
I used the searchfunction but couldn´t find an answer.
I´ve integrated jquery superfish plugin (NAVSTYLE!) in joomla. No Problem
so far.
I positioned the list items of the first Nav. Row via css with different gaps between the li´s.
f.e:
- .item-103{
- margin-right:45px;
- }
- .item-104{
- margin-right:9px;
- }
What I´m lookin for is a way to position the submenu not on the very left under the first NavRow, but centerd under it´s parent link (Opener from the first navigation row).
I thought I could code this by jquery offset. Means calculate the x position of the parent element then the width of the submenu and then set the x value of the submenu. But this fails at first step as I don´t get correct values from offset?? Any tips?
- var p = $(".item-104").offset();
- alert (p.left);
Gives me a wrong value for:
<ul class="menu sf-menu sf-navbar"> <li class="item-101"><a href="/test.com/home" >Home</a></li>
<li class="item-102 deeper parent">
<a href="/contact/" >contakt</a><ul><li class="item-109"> ...
for better understanding, an image what I´m looking for (submenu centered under its parent link) :

thanks for help,
tony