From 7d3e357e0a962e062c982cbcd4fa525f62d3e1d8 Mon Sep 17 00:00:00 2001 From: Alexander Bilz <mail@alexbilz.com> Date: Thu, 06 Aug 2020 16:59:51 +0000 Subject: [PATCH] Added additional description on how to use the multilingual mode --- README.md | 8 ++++++++ 1 files changed, 8 insertions(+), 0 deletions(-) diff --git a/README.md b/README.md index 9478113..2f34c72 100644 --- a/README.md +++ b/README.md @@ -99,6 +99,14 @@ weight = 2 LanguageName = "DE" ``` +There are two ways of translating your content either by adding a suffix in the filename eg. `mypost.de.md` or by setting a contentDir (a certain directory) for each language. [Link to the Hugo documentation](https://gohugo.io/content-management/multilingual/). If you want to use the option with the `contentDir`, you will have to add the `contentDir` parameter for each language: +```toml +[languages] + [languages.en] + contentDir = "content/english" + languageName = "EN" + weight = 1 +``` To make sure your menu is linking to the correct localized content, make sure that you customize the menu items to inlude the language prefix. Your menu might look like the following: ```toml [[Languages.de.menu.main]] -- Gitblit v1.10.0