Menu
Knowledge Base Twig Syntax & Code (2.0)
Help Center
back
Twig Delimiters Example Definition
{% ... %} {% if su.article.title != ""%}
            :
            {{ su.article.title }}{% endif %}
Used to execute statements (for loops, if statements, block statements, etc.)
{{ ... }} {{ su.legacy.token( "time" ) }} Used to print the content of variables or the result of evaluating an expression
{# ... #}   Used to add comments in the templates
Legacy Tokens  
{{ su.legacy.token( "adlinkstext1" ) }}   Include a text ad for a specific zone
{{ su.legacy.token( "adlinkspanel1" ) }}   Include a panel ad for a specific zone 
{{ su.legacy.token( "adminlinks" ) }}   Adds the administrative links CSS: bottom_links 
{{ su.legacy.token( "breadcrumbs" ) }}   Prints a list of pages back to the home page with links. CSS: breadcrumbs, breadcrumbs_separator, breadcrumbs_curren
{{ su.legacy.token( "childarticles" ) }}   List of child articles of a specific article id CSS: childpages
{{ su.legacy.token( "content" ) }}   The text of the page content
{{ su.legacy.token( "custom1" ) }}
  • custom1
  • custom2
  • custom3
  • custom4
Custom template area 1 
{{ su.legacy.token( "date" ) }}   Displays the current date
{{ su.legacy.token( "eventsnew1" ) }}   Listing of calendar's upcoming events in a specific calendar category. You can define these categories in Calendar Configure. CSS: eventsnew, eventsnew-title, eventsnew-description 
{{ su.legacy.token( "feature..." ) }}
  • image1
  • imageshow1
  • title1
  • titletext1
  • text1
  • url1
Works with the features module
{{ su.legacy.token( "footerlinks" ) }}   Adds the footerlinks
{{ su.legacy.token( "googlemap" ) }}   Display a Google map. It must be configured in Admin Management -> Site Configuration and Navigation.
{{ su.legacy.token( "login" ) }}   Link to members login page
{{ su.legacy.token( "meta-....." ) }}
  • -description
  • -keywords
Display the automatic website meta-description when you use a custom DOCTYPE
{{ su.legacy.token( "menu-..." ) }}
  • -vertical
  • -horizontal
  • Dynamic subpage flyout menu token. CSS: See menu config
  • Dynamic subpage dropdown menu token. CSS: See menu config 
{{ su.legacy.token( "nav-" ) }}
  • -vertical
  • -horizontal
  • -horizontal2
  • Vertical text navigation links CSS: vertical-links 
  • Horizontal text navigation links CSS: navlinks
{{ su.legacy.token( "navigation" ) }}   Display the main navigation items in a LI list
{{ su.legacy.token( "newswhatsnew" ) }}   Listing of most recent news texts CSS: whatsnew, whatsnew-title, whatsnew-description
{{ su.legacy.token( "noticelink" ) }}
  • noticelink1
  • noticelink2
Privacy and legal notices links, used with the Notice module CSS: footer
{{ su.legacy.token( "poll1" ) }}   Display a poll item for a specific poll id CSS: pollquestion, polltotals, pollarchive
{{ su.legacy.token( "rssdigest" ) }}   Build a RSS digest for a specific RSS feed
{{ su.legacy.token( "search" ) }}   Website search box CSS: search_field
{{ su.legacy.token( "siblingarticles" ) }}   List of articles that share the same parent page CSS: siblingpages, siblingpages_current
{{ su.legacy.token( "signup" ) }}   Link to members signup page 
{{ su.legacy.token( "sunset" ) }}   Sunset schedule
{{ su.legacy.token( "sharelinks" ) }}   Display the "Print | Email | Post" links 
{{ su.legacy.token( "time" ) }}   Display the current time
     
Su calles    
su.article.title    
su.content    
su.footer    
su.theme.css {{ su.theme.css("offcanvas.css") }} Create a link tag for your css file
su.theme.js {{ su.theme.js("offcanvas.js") }} Create a script tag for javascript file
su.theme.config {{ su.theme.config("logo-image" ) }} Grabs information in theme config based off the name
loop.index    
loop.last    
su.social    
su.calendar.events    
event.date
  • Date
  • url
  • title
 
nav.name
  • name
  • target
  • url
  • Grabs nav name from site configuration and navigation
  • Grabe nav target from site configuration and navigation
  • Grabs nav url from site configuration and navigation
su.theme.asset    
su.misc.privatelabel    
su.site.
  • address
  • city
  • state
  • zip
  • name
  • second line
  • navigation