in

SharePoint Blogs

The Best Place for SharePoint-related Blogs

helloitsliam's blog

MOSS2007 – JavaScript Item Menus Part 2 (Real World Examples)

In the last article we looked at hiding existing menu items and also adding new sub menu items. In this article we will look at adding our own custom menus and sub menu items within the same framework as before. We will use the same code as last time but build on it slightly. The objective now is to create a new menu at the same level as the “Send To” menu and then add some sub menu items. For this example the sub menu items will simply link to external website addresses. To start with let’s modify the code as shown below:

This code block will add the relevant menus we described above. When you now access the UI the menu items should be shown as below:

We could enhance this slightly further also by adding a simple hierarchy of menu items. In the real world you probably wouldn’t do this as it can be quite complex to use and administer. The code needs to be changed as below:

This will then render as below:

With a little extra JavaScript and a little creativity you can create very complex menu structures with different events that are fired based on the link clicked. The above examples are just some of the things you can do with it. Big Smile

Comments

 

Lchungue said:

As "Jens" mentionned on the 3rd part, images don't seem to appear...

Thanks !

June 27, 2007 2:45 PM
 

kane county teachers credit union aurora illinois said:

kane county teachers credit union aurora illinois

September 8, 2007 6:22 AM
 

sugengnn said:

images don't seem to appear

January 24, 2008 9:14 PM

Leave a Comment

(required )  
(optional )
(required )  
Add

Need SharePoint Training? Attend a SharePoint Bootcamp!

Posts (c) their respective authors. Everything else (c) 2007 SharePoint Experts