Kentico CMS 6.0 Controls

Configuration

Configuration

Previous topic Next topic Mail us feedback on this topic!  

Configuration

Previous topic Next topic JavaScript is required for the print function Mail us feedback on this topic!  

The following properties of the CMSListMenu control can be set or used in the API:

 

All of the common properties from:

 

CMS controls - common properties

CMS navigation - common properties

 

In addition, the following properties are available:

 

Property Name

Description

Sample Value

DisplayHighlightedItemAsLink

Indicates whether the highlighted item should be displayed as a link.

 

DisplayOnlySelectedPath

Indicates whether all sub-menus should be displayed or just the sub-menu under the highlighted (selected) item.

 

EncodeMenuCaption

Indicates whether HTML encoding should be applied to the captions of menu items. Useful only in special cases where the names of the displayed documents contain HTML code.

 

FirstItemCssClass

Specifies the CSS class for the first item on every menu level.

"ListMenuFirstItem"

HighlightedNodePath

Path of the item that should be highlighted as if it were selected. If you omit this value, the control automatically uses the current alias path from the aliaspath querystring parameter.

"/products/PDAs"

HoverCSSClassName

Name of the surrounding CSS class that is used to define styles for the hover effect if you want to render a drop‑down menu.

"Horizontal"

ItemIdPrefix

Prefix placed before each item ID. You can use it to keep IDs unique if you have several CMSListMenu controls on the same page.

"submenu"

LastItemCssClass

Specifies the CSS class for the last item on every menu level.

"ListMenuLastItem"

LoadDataAutomatically

Indicates whether data for the control should be loaded automatically. By default, the data is loaded automatically.

 

If you set this property to false, you can enter a custom DataSet into the DataSource property and then call the ReloadData(false) method.

 

OnMouseOutScript

OnMouseOut script for menu items. You can use macro expressions here.

 

OnMouseOverScript

OnMouseOver script for menu items. You can use macro expressions here.

 

OrderBy

Gets or sets the ORDER BY clause of the SQL statement.

 

Please be aware that it is necessary for the root of the displayed tree (or sub-tree) to be first in the resulting order, otherwise all documents may not be displayed correctly. This can be ensured by having the value of this property start with the NodeLevel column, such as in the sample value.

"NodeLevel, NodeOrder"

RenderCssClasses

Indicates whether CSS classes should be rendered for every element. If set to false, only the first and last item of a menu level will use a CSS class.

 

RenderedHTML

Allows you to get or set the HTML code rendered by the control.

 

You need to set this property before the Render event - e.g. in the OnLoad event.

 

RenderImageAlt

Indicates whether the ALT attribute should be rendered for images used in the menu (for XHTML compatibility).

 

RenderItemID

Indicates whether a unique ID should be rendered for every menu item.

 

RenderLinkTitle

Specifies if the document name should be rendered as a TITLE tag of links (for better accessibility).

 

UrlTarget

Specifies the target frame for all URLs.

"_blank"

 

Mentioned method:

 

Method Name

Description

ReloadData(bool forceLoad)

Reloads the data.

 

If the forceLoad parameter is set to false and a value is assigned to the DataSource property, the properties of the CMSListMenu control are not used and only the data from the DataSource is loaded.