API
Version 7.x > API > Extending Css List Menu View modes: 
User avatar
Member
Member
John - 2/12/2013 6:40:01 AM
   
Extending Css List Menu
Hello

I wish to extend the CSS list menu (cms menu) so that clients would be able to add an image in the drop down of each navigation item.

I was thinking of adding additional fields to the page document type so clients can associate images with them, but I'm still thinking of a solution as to how to extend the CSS list menu web part to output them. Am I able to access document properties from within the web part as from what I've seen I can only manipulate the rendered html in the RenderedHTML property.

Does anyone have any ideas?

Much thanks
John

User avatar
Kentico Legend
Kentico Legend
Accepted solutionAccepted solution
Brenden Kehren - 2/12/2013 7:39:05 AM
   
RE:Extending Css List Menu

Your best bet would be to use a repeater and nested repeaters or use the Hierarchical Viewer. With that webpart you can define an unlimited number of transformations and assign them as needed. Your transformations can contain a table layout, UL, OL, etc. You define it which works very well and doesn't involve any coding of a webpart.

User avatar
Member
Member
John - 2/12/2013 11:43:13 PM
   
RE:Extending Css List Menu
Thanks FroggEye I'll look into that.

User avatar
Member
Member
John - 2/12/2013 11:44:52 PM
   
RE:Extending Css List Menu
PS - I remember the reason I decided not to pursue nested repeaters. From what I could see they only support two levels of nesting. The menu I'm building is three levels deep.

User avatar
Kentico Support
Kentico Support
kentico_janh - 2/13/2013 7:20:11 AM
   
RE:Extending Css List Menu
Hello,

It is possible to achieve more than two levels using nested repeater, but since version 6 and hierarchical transformation, this is not recommended anymore. Please follow the article below about building own menus using hierarchical transformations:

How to build up a menu using the hierarchical transformation

Best regards,
Jan Hermann