Skip to main content

Multilingual Guide

The TanaFlows theme supports a professional and minimalist multilingual feature. You do not need to modify complex system configuration files. Simply follow the instructions below to activate and publish multilingual articles.


1. How Multilingual Works in TanaFlows

The TanaFlows theme manages translation links intelligently to ensure the best experience for readers:

  • Static Pages (Homepage, Blog, Categories): The language switcher is always visible, allowing users to freely switch between language versions.
  • Content Pages (Posts, Pages):
    • If a translation exists: The language switcher works normally, allowing readers to click and read the article in the other language.
    • If not translated (No #multilingual tag): The language switcher will be grayed out and locked (unclickable), displaying the text “Not translated” to prevent readers from clicking and encountering a blank page (404 error).

2. Configuration Steps in Ghost Admin

Go to Ghost Admin > Settings > Design > Custom Settings of the TanaFlows theme and enter the following information:

  1. Enable Multilingual: Toggle the switch to On.
  2. Languages: Enter the list of site languages in the format: language_code|Display_Name, separated by commas.
    • Example: vi|Tiếng Việt,en|English
    • Note: The first language in the list (in this case, vi) will be the Default Language (its URL path will not contain a language prefix).
  3. Root URL: Enter your main website domain.
    • Example: https://tanaflows.com (do not add a trailing slash /).

3. Writing and Linking Multilingual Posts

To allow readers to switch between translations of a post, follow this workflow:

  1. Publish the Post in the Default Language (e.g., Vietnamese)

    • Set the post URL path (Slug). Example: huong-dan-su-dung
    • Add the internal tag #multilingual to the post.
  2. Publish the Post in the Second Language (e.g., English)

    • The URL path (Slug) must match exactly with the default post in Step 1. Example: huong-dan-su-dung
    • Add the internal tag #multilingual to the post.

Info

When both posts share the exact same slug and have the #multilingual tag, the system will automatically link them. A reader on the Vietnamese post who selects “English” will immediately be redirected to the English version, and vice versa.


4. Localizing Default Labels (Localization)

If you want to change the static text labels shown on the interface (e.g., translating “Not translated” or “Back to Home”):

  1. Open the locales/ directory inside your theme folder.
  2. Open the corresponding language file (e.g., vi.json for Vietnamese, en.json for English).
  3. Find the key you want to edit and enter your preferred translation.
  • Example in vi.json:
    "Not translated": "Chưa có bản dịch",
    "Back to Home": "Quay lại trang chủ"