To scrap the menu, simply run
document.getElementById('domMenu_main').innerHTML = '';
domMenu_activate('domMenu_main');
The menu definition can be manipulated, as in the following snippet,
which adds a third item to the first submenu.
domMenu_data.get('domMenu_main').get(1).set(3,
new Hash(
1,
new Hash(
'contents', 'New Item',
'uri', 'http://example.com'
)
)
);
It could be easier, I agree...perhaps creating a function that did the
nasty work would be the best way to handle it.
/dan
On 4/4/06, raydar <tom...@daugherty.com> wrote:
>
> I have a list of menu items from dom_menu_items. I need to dynamically
> add other items based on a database. Any ideas?
>
>
> >
>
--
Daniel Allen
Registered Linux User #231597
Mojavelinux.com: Open Source Advocacy
http://www.mojavelinux.com
While I make a strong effort to keep up with my email on a daily basis,
life and work come first and, at times, keep me away from my mail for a
while. If you contact me and then don't hear back for more than a week,
it is very likely that I am excessively backlogged or the message was
caught in the filters. Please don't hesitate to resend a message if
you feel that it did not reach my attention.