Create a Calling Page Index Block
This Index Block, which is usually referred to as a
calling page or
current page Block, is
one of the most used Blocks in Cascade. To further explain the
purpose behind it's functionality, this Block will access the
stored content for whatever Page you are currently looking at and
load it into what region this Block is assigned to.
- Navigate to the BaseFolder → _cascade → blocks → index directory in the Asset Tree
- Use the menu bar to create a New → Default → Block
- For the Block Type ** select **Index Block
- For the System Name field type calling page
- For the Index Type field choose Folder Index
- For the Depth of Index field type 0
- For the Indexed Asset Types field check Pages
- For the Rendering Behavior field select Render normally, starting at the indexed folder
- For the Page XML field select Render page XML inline
- For the Indexed Asset Content field check Regular Content and User Metadata
- For the Other Indexed Info field check Append Calling Page Data
- Click Submit
The different sections of options correspond to a number of different things.
Index Type: This describes how the Block will gather information in the system. It will use the folder structure (Asset Tree).
Depth of Index: This dictates how many levels forward (deep) the Block will search for gathering information. Relative to the asset you are currently working with, siblings are level 1, nieces/nephews (children of siblings) are level 2, and so on.
Indexed Asset Types: You can limit the types of
assets that the Block will gather information from.
Rendering Behavior: This is the behavior (logic) that is used to traverse the folder structure. "Render normally" follows a brute force path to determine which assets should be indexed relative to the Page you are currently viewing. It also takes into account the "Depth of Index" specified to limit how many levels forward (deep) to gather.
Page XML: This option corresponds to whether or not you would like to have access to content gathered from the Data Definition level. The reason you can choose to not return that information is that Index Blocks can be used for a variety of other purposes that just rendering content for a single Page. In the case of dynamically creating a navigation based on the Pages that exists contextually, Page content is not something that is used when building an XHTML list of Page titles. Therefore it is not advised to include the page content in the set of XML data that is made available in a region.
Indexed Asset Content: These also correspond to different aspects of asset information that can be included or excluded from the returned data set. "Regular Content" will provide you with the "Display Name" and path information of the asset. "User Metadata" will include anything collected from the Metadata Set of the asset -- Title, Summary, Keywords, Description, Author, Start Date, etc.
Other Indexed Info: This section is geared toward generating information that could be used for custom reports. The "Append Calling Page Data" box is how the information for the Page you are currently viewing is included. As a by-product of the "Depth of Index" above being 0, information for the current Page is ignored in addition to information from sibling assets.
Because this type of Index Block requires a context page to render, previewing the Index Block will show:
To preview the generated XLM structure, you can to use the Preview Format options when creating/editing a Format:
- Select Block for asset type
- Choose your newly created calling page Index Block
- Choose your desired context page