Dynamic Template Positions

The dynamic template positions offer a flexible way to mange module positions in the template configuration. To say it simply; this is a user interface to handle Jdoc Statements and modChrome. A dynamic position can contain multiple module positions. And on a module position you can assign multiple modules.

In the JYAML default template the following dynamic positions are already predefined in the HTML-Templates.

  • col1_content (within the Div .ym-col1)
  • col2_content (within the Div .ym-col2)
  • col3_content (within the Div .ym-col3)
  • nav_main (within the Div #nav)
  • nav_top (within the Div #topnav)

You can add your own dynamic positions in an HTML-Template. For this you must add a special JDoc Statement in your desired HTML-Template (e.g. /html/index/default.php), which is only available in JYAML. For example, we will add the position my_footer in /html/index/default.php. You will need to add the code "<jdoc:include type="jyaml" name="my_footer" />" and insert it at the appropriate place on the HTML-Template in your favorite editor and save the file.

Now open/update the template settings in the Joomla! backend and it automatically appears as a new dynamic position my_footer my_footer.

Following position types are available:

  • Moduleposition (type="modules")
  • Module (type="module" - a single module)
  • Component (type="component" - output of the component)
  • Message (type="message" - Joomla! system messages, errors, warnings, etc.).
    Note: The Message output is already integrated into the default HTML-Templates, to be suppressed not by accident.

If you select Module or Moduleposition as type, additional selection boxes will be activated/visible. These appear at the corresponding position to select the style (modChrome function). Depending on the module style more style options does appear (modChrome attributes).

As you create your own modChrome functions in JYAML you can lean in the Development Portal.

The following module styles are included by default:

  • none (Joomla! default)
  • html5 (Joomla! default)
  • xhtml (Joomla! default)
  • rounded (Joomla! default)
  • jyaml (like xhtml, but with options)
  • rawlinks (only links with '<a>' and an spacer will be shown)
  • grids [formerly subtemplates] (output of several modules as a multi-column grid - YAML Grids)
    When a module is loaded into the subtemplate style, you can adjust the column width with "Module Class Suffix". You must only make sure that all modules has no more as 100%. The following values ​​can be used: 10%, 15%, 20%, 25%, 30%, 33%, 35%, 38%, 40%, 45%, 50%, 55%, 60%, 62%, 65% , 66%, 70%, 75%, 80%, 85%, 90%. If no percentage values ​​are set, the columns are automatically splitted evenly.
  • accessible_accordion (output of several modules with an Accordion effect (accessible; i.e. to use with keyword)
  • accessible_tabs (output of several modules as Tab-Navigation (accessible; i.e. to use with keyword)
  • accessible_slider (output of several modules as a Slider (accessible; i.e. to use with keyword)