Show TOC

Creating Lists with Alternative LayoutsLocate this document in the navigation structure

Context

You want to depict the content of the same XML files in multiple iViews with different layouts.

Example

Examples:

You want to display the title, summary, and image of each news item in a wide iView.

You only want to display the title for each news item in a narrow iView.

Procedure


  1. Create a new form, for example RenderListItem2 , in the XML Forms Builder.

    1. Choose the Project Browser tab page .

    2. In the context menu of the root node, choose Add Form.

    3. In the properties of the form, choose the class Show Form.

  2. In the configuration of the KM user interface, create a new set of XML form resource renderer settings.

    Choose Start of the navigation path System Administration Next navigation step System Configuration  Next navigation step  Knowledge Management  Next navigation step  Content Management  Next navigation step  User Interface  Next navigation step  Settings  Next navigation step  Resource Renderer Settings  Next navigation step XML Resource Renderer Settings. End of the navigation path

    Parameter

    Value

    XML Forms Transformation

    Name of the form that you created in step 1.

    Command Display

    For example, link .

    Folder Command Group

    For example, NewsDisplayGroup.

    Link Command Group

    For example, NewsDisplayGroup.

    Resource Command Group

    For example, NewsDisplayGroup.

    Resource Renderer

    NewsRenderer

  3. In the KM user interface configuration, create a new layout set.

    Choose Start of the navigation path System Administration Next navigation step System Configuration  Next navigation step  Knowledge Management  Next navigation step  Content Management  Next navigation step  User Interface  Next navigation step  Settings  Next navigation step  Layout Set.  End of the navigation path

    You can duplicate an existing layout set, for example, NewBrowser , and then choose another resource renderer for the duplicate.

    Parameter

    Value

    Collection Renderer

    For example, NewsDisplayCollectionRenderer.

    Resource Renderer

    Name of the set of resource renderer settings that you created in step 2.

    Commands for the details menu

    For example, DetailsGroup.

    Layout Controller

    For example, SimpleLayoutController.

  4. Create an iView.

    Use the KM Navigation iView iView template . Enter the data in the table below into the iView properties.

    Property

    Value

    Layout Set

    Name of the layout set that you created in step 3.

    Layout set mode

    Exclusive

    Path to initially displayed folder

    Path to the folder in which the XML documents are stored.

    Example : /documents/myNews

    Path to root folder for navigation

    Path to the folder in which the XML documents are stored, or to subordinate folders.

    Example : /documents/myNews

    Note

    If a folder contains XML documents that you created using Edit forms from different projects, make sure that there is a form with the same name in each project.

    For example, if you create news items as well as FAQs in the folder /documents/myNews , create a form with the same name (for example, RenderListItem2 ) in both XML Forms Builder projects.