Websydian v6.1 online documentationOnline documentation - WebsydianExpress v3.0

Insert a Menu Item as a Link on a Page

Overview

In some situations you will wish to let a page contain a link, which activates a menu item - without having to insert a menu.

This link must of course only be shown to the same users who would have access to the menu item in a menu.

This section describes how you can do this - without having to involve any developers.

In the following section it will be assumed that the functionality is already available as an element in the site structure tree.

Create alias

Technically the link will be created by using a special replacement marker in the template. This replacement marker must specify the site element (menu / frameset / business process / URL) from the site structure tree to load.

To make it possible to refer to this site element you will first have to define an alias (which is the text you will insert in the template).

The alias is created using the menu point "General->Alias" in the administration menu. Press "Insert" and enter the necessary information for the alias. It is the information entered in the field "Alias", which will be written in the template, so we recommend that this text is as self explanatory as possible.

Specify alias for element in site structure tree

After creating the alias you have to specify that this "belongs" to the specific element in the site structure, which you want the link to activate.

Select the site element, you wish to be able to activate as a link, in the site structure tree and press "Menu service". Select the alias you have created in the drop down box and press "Apply".

Please note the this alias now refers the specific link between the selected site element and the parent element in the tree. If the same site element is a child in more than one place in the tree it is the information for the selected link, which is used when the alias is referenced.

Insert replacement marker in template

To reference the alias insert the following code in the template (references the alias "AliasText"):

/(MENU-AliasText)

/(WSBEGIN)
    <p><a target="/(WSMNUTAR)" href="/(WSMNUURL)">/(WSMNUTXT)</a></p>
/(WSEND)

The page generated by the template will now show a link - the text will be the menu item name of the site element. When this link is activated it will work in exactly the same manner as if the menu item had been pressed in the menu.