Start page
Start page
Start page

Start page / Template development / Link templates / Configuration / for internal links

Configuration for internal links (internalLink) Available up to FirstSpirit Version 5.0

"internalLink" screen form example

The diagram on the left-hand side shows an example of a screen form for an internal link. In the example all the possible input fields for this type of link are displayed.

If an explicit configuration is not given for an instance of an internal link, as a default all components are displayed with their default values.

The template developer can configure each input field project-specifically by giving the "name" attribute in the <CMS_PARAM> tag (cf. Chapter Configuration). The attribute names, through which the respective input fields or selection lists can be influenced are displayed in the diagram in italics. (To enlarge, please click the diagram!)

The following fields can be used for all instances of the standard link type "internalLink", for configuring internal links (within the project):

Field name

Description

sitestoreref

The "sitestoreref" field is an input component for the selection of a reference from the project's Site Store. The standard behaviour of the input component can be changed using the configuration of the input component, for example by displaying a specific pre-selected reference:
<CMS_PARAM name="sitestoreref" value="pageref:xyz" default="1"/>

If the optional attribute value="showmediastore" is given in the configuration:
<CMS_PARAM name="sitestoreref" value="showmediastore"/>
apart from the tree view of the Site Store, the tree view of the Media Store is also displayed to the editor.

If the optional attribute value="hidesitestore" is given in the configuration:
<CMS_PARAM name="sitestoreref" value="hidesitestore"/>
the locale Site Store of the project is hidden, but Site Stores of potentially existing remote projects are displayed to the editor. (In this case the attribute remote must be given.)

The selected reference must be resolved in the source text of the link template by means of $CMS_REF(#link.sitestoreref)$.

section

The "section" field is an input component for selecting a section. As a default, all sections of the page whose page reference was selected by the editor in the "sitestoreref" input component are displayed.
The standard behaviour of the input component can be changed using the configuration, for example by displaying a specific pre-selected section of the page:
<CMS_PARAM name="section" value="Text/Picture" default="1"/>


If a section is selected in the screen form, in addition "section_anchor" and "section_id" can also be used.

section_anchor

"section_anchor" only has a value if a section was selected in the "section" selection list
The "section_anchor" value can be used to compose an HTML go to marker (anchor) on the section. A template developer requires such anchors to set go to markers within the page in extensive page contents, for example for a table of contents or to return to the first section at the end of a page.
The output must be in the source text of the link template by means of $CMS_VALUE(#link.section_anchor)$ .
Important: It is necessary to activate the " tag" attribute for the section template of the target section (in the template area)! In a preview, generation or deployment the " tag" is generated automatically.

section_id

"section_id" only has a value if a section was selected in the "section" selection list
the "section_id" value can be used to access the ID of the selected section.
Example:
$CMS_REF(#link.sitestoreref)$
$CMS_IF(!#link.section_id.isEmpty)$
#$CMS_VALUE(#link.section_id)$
$CMS_END_IF$

Unlike the section name (for example, as used in "section_anchor") the ID is unique throughout the whole project. "section_id" can therefore be used for reliable, unique referencing of a section.
Important: It is necessary to enable the " tag" attribute for the section template of the target section (in the template area)! In a preview, generation or deployment the " tag" is generated automatically.

text

The "text" field is an input component for entering a link text. Any text can be entered in the field which is to be linked. The standard behaviour of the input component can be changed via the configuration.
Example:
<CMS_PARAM name="text" label="Link text"/>

comment

The "comment" field is an input component for entering a comment. The editor can enter any comment text in the input field which can be displayed, for example, as a "tooltip". The standard behaviour of the input component can be changed via the configuration.
Example:
<CMS_PARAM name="comment" value="Please click here!"/>

linktemplate:

The "linktemplate" field is a selection list for selecting a link template. As a default the selection list contains all link templates of the current instance of the link template type. (Explication: see Link Templates )
The editor can select the link template to be used for creating the link from the list.
The standard behaviour of the input component can be changed via the configuration of the input component.
The selection list can be pre-filled by the template developer, for example with any number of valid link template names, by defining several parameters. The unique identifier must be given for the attribute value.
<CMS_PARAM name="linktemplate" value="myInternalLink.standardLink1"/>
<CMS_PARAM name="linktemplate" value="myInternalLink.standardLink2" default="1" />
<CMS_PARAM name="linktemplate" value="myInternalLink.standardLink3"/>

The elements are displayed in the list in the order configured by the template developer.

mediaref

The "mediaref" field is an input component for the selection of a media object to be linked from the project's Media Store. The standard behaviour of the input component can be changed via the configuration of the input component.
Example:
<CMS_PARAM name="mediaref" value="media:abc" default="1"/>
The selected reference must be resolved in the source text of the link template by means of $CMS_REF(#link.mediaref)$ .

target

The "target" field is an input component for selection of a target frame for the link, for example in the current window or in a popup window. The link is opened in the selected target frame.
The standard behaviour of the input component can be changed using the configuration of the input component, for example the template developer can pre-assign multiple default values to the list:
<CMS_PARAM name="target" value="_top"/>
<CMS_PARAM name="target" value="_self" default="1"/>
<CMS_PARAM name="target" value="_blank"/>

The "value" attribute can be used to make the usual HTML frame identifiers as well as project-specifically defined frames available to choose from.

language

The "language" field is an input component for selecting a language for the link. As a default, all the project's languages are displayed in the selection list.
The standard behaviour of the input component can be changed using the configuration of the input component, for example the template developer can preselect a language:
<CMS_PARAM name="language" value="DE" default="1"/>


remote

The "remote" field defines which remote project is available for selection of a reference from the Site Store. The symbolic name of the remote project must be given for the attribute value.
<CMS_PARAM name="remote" value="symbNameRemoteproject"/>

If the optional attribute value ="showremotesitestore" is given in the configuration of the "sitestoreref" field:
<CMS_PARAM name="sitestoreref" value="showremotesitestore"/>
, apart from the Site Store of the internal project, the Site Store of the remote project is also displayed to the editor.

If the optional attribute value ="showremotemediastore" is given in the configuration of the "sitestoreref" field:
<CMS_PARAM name="sitestoreref" value="showremotemediastore"/>
, apart from the Site Store of the internal project, the Media Store of the remote project is also displayed to the editor.

remotemedia

The "remotemedia" field defines which remote project is available for selection of a media object from the Media Store. The symbolic name of the remote project must be given for the attribute value.
<CMS_PARAM name="remotemedia" value="symbNameRemoteproject"/>

If the optional attribute value ="showremotemediastore" is given in the configuration of the "mediaref" field:
<CMS_PARAM name="mediaref" value="showremotemediastore"/>
apart from the Media Store of the internal project, the Media Store of the remote project is also displayed to the editor.

If the optional attribute value ="remoteonly" is given in the configuration of the "mediaref" field:
<CMS_PARAM name="mediaref" value="remoteonly"/>
the editor is only displayed the Media Store of the remote project.

   

© 2005 - 2012 e-Spirit AG | All rights reserved. | Last change: 15.12.2010