Reference → Use shortcodes

Use shortcodes

How to use dynamic placeholder tokens like {{site_title}} in your content

Shortcodes are short placeholder tokens — {{site_title}}, , {{page_title}} — that SGEN replaces with the current value at render time. Use them so a single piece of footer copy or header text stays accurate as site settings change.

What is this for?

Shortcodes let you write "Call us at " once and have every page render your current phone number. Change the number in General Settings and every page updates at the same time, no per-page edits.

The Shortcodes Helper panel is a read-only reference listing every available token in three categories: Basic, Ecommerce, and Locations, plus a Data Information tab for context.

Good use cases

Example 1: Keep Acme's footer copyright accurate automatically. Write © {{site_title}} 2026. All rights reserved. into the Footer legal row. Acme Coffee Roasters has site_title set to "Acme Coffee Roasters" in Settings. Before expansion (what you type) vs after (what visitors see):

Footer legal row — source vs public
Footer legal row — source vs publichtml
// You type:
© {{site_title}} 2026. All rights reserved.
// Public visitor sees (after SGEN expands the token):
© Acme Coffee Roasters 2026. All rights reserved.
Top: what you type into the admin. Bottom: what visitors see on any Acme page.

If Acme renames itself to "Acme Roastery" in Settings → General → Site Title, every page's footer updates on the next load — no per-page edit.

Example 2: Reuse the business phone across the site. Acme uses Call us at in the Header CTA and in a footer widget. Changing the phone in General Settings from (503) 555-0142 to (503) 555-9999 updates every page at once.

Example 3: Embed current page metadata on shared templates. Use {{page_title}} and {{page_url}} inside a shared SGB element (a breadcrumb component, a "Share this page" CTA) so each page shows the right title / link without per-page editing. Acme's shared "Share on X" CTA uses this pattern:

Shared SGB template — Share on X button
Shared SGB template — Share on X buttonhtml
<a href="https://twitter.com/intent/tweet?text={{page_title}}&url={{page_url}}"  target="_blank"> Share on X
</a>
// On /blog/behind-the-2026-harvest this expands to:
// text=Behind the 2026 Harvest at Acme
// url=https://acmecoffee.com/blog/behind-the-2026-harvest

What NOT to use this for

  • Do not invent tokens. Only the tokens listed in the helper work. Typos ({{sitetitle}}, {{biz_phone}}) render as literal text on the public site.
  • Do not wrap the token in quotes or format marks. Write exactly {{site_title}} — the curly braces are the delimiter.
  • Do not use shortcodes for sensitive data. Tokens render wherever you put them; do not use them for admin-only values.

How this connects to other features

  • General Settings — most Basic tokens ({{site_title}}, {{site_url}}, ) read from Settings → General.
  • Ecommerce — Ecommerce tokens read from Ecommerce → Configuration; available only when Ecommerce is enabled.
  • Locations — Location tokens read from Locations; available when a locations directory is active.
  • SGB pages / templates — you can paste any shortcode inside an SGB text element and it renders at publish time.

Before you start

  • The value the shortcode should show (site title, phone, address) is set in the matching Settings area.
  • You know which panel (Basic / Ecommerce / Locations) your token lives in.

Where to go

  1. Open the left navigation.
  2. Click Appearance → Shortcodes Helper. The page shows a tabbed table of every available token:
Shortcodes Helper

Shortcodes Helper

TagParametersDescription
{{site_title}}-Outputs the site title as defined in settings.
{{site_description}}-Displays the site's description.
{{site_url}}-Returns the base URL of the site.
jerome@sgen.com-Outputs the default site email address.
-Outputs the business phone from General Settings.
-Outputs the full business address.
-Outputs the formatted business hours.
{{page_title}}-Title of the current page.
{{page_url}}-URL of the current page.
Blog-Value of a custom object (replace name).
https://docs.sgen.com/login-URL for the login page.
https://docs.sgen.com/logout/?_nonce=dkD5TE8xc66T3%2B%2FhyUTD6B0Pe%2BAlchGtkNeQ8Cj%2FvIU%3D-URL for the logout action.

Showing 12 of 59 Basic shortcodes. Full list on /sg-admin/appearance/shortcodes_helper.

  1. Copy the {{token}} text from the Tag column.

Steps

1. Copy a token

Click the token in the table (or triple-click to select and copy). The exact string to paste is what's inside <code>...</code>.

2. Paste into your content

  • Footer / Header text — paste inside any widget or button label.
  • SGB page element — paste inside a text or paragraph element.
  • Email templates — paste inside the email body (where supported).

3. Save and verify on the public site

Save the container (Footer, page, email). Visit the public page and verify the token rendered as the expected value (e.g. your site name, phone, address).

What success looks like

  • On the public site, the {{token}} text is replaced by the current value.
  • If you change the source value in Settings and reload, the rendered text updates.

What to do if it does not work

  • My token renders literally on the page. Double-check spelling — the helper's Tag column is the source of truth. Typos render as-is.
  • is empty. Set a business phone in Settings → General. Empty tokens render empty.
  • An Ecommerce token renders empty. Enable Ecommerce and set the corresponding value in Ecommerce → Configuration.

Next step

On this page