dktue
May 13, 2019, 1:59pm
1
I have a website that has three translations but all are german: de-de (Germany), de-ch (Switzerland) and de-at (Austria). Most pages are identical but some have different images.
Image-fallback works perfectly so most images are only in the first-order-translation (de-de) and only some localized pictures are in the other translations.
What I want now: A fallback for content: I want most pages to only exist in the first-order-translation (de-de) and not having to copy them to de-ch and de-at.
Any idea on how to accomplish this?
Hello,
First of all pushing a topic that never got replies is not good practice.
Second this issue has come up before in the forum. In the future please use the search functionality in the forum before opening duplicate topics.
Just getting started with Hugo, and so far I’m loving it!
My site is international… I’ll be translating some, but not all content - some never, some will be delayed.
I understand that if use i18n strings and one isn’t translated it will fallback to the default language - which is great - but what about when I use translation within content - for example:
/content/mypage.md
/content/mypage.fr.md
/content/mypage.de.md
So in this case, I have three translations - the original in English and t…
There is also a relevant GitHub issue that is currently open:
opened 08:29PM - 06 Oct 16 UTC
closed 08:39PM - 06 May 23 UTC
Enhancement
Keep
Outdated
I propose that there should be a convenient way to crosspost a post in multiple … languages.
## An example use case
On my personal site I currently write articles in English first and then I create a translated version of that in Swedish.
But I am thinking about focusing more on writing only in English. But I still want my visitors that go to the swedish site to be able to see the new content even though it is only available in English. I want my visitors to be aware that there are new content on the site.
Those posts/articles that do have a Swedish translation should of course show that translation on the Swedish site but for posts/articles that is available only in English I want to be able to crosspost them so they also show up on the swedish site.
## How to do this
Currently we have .Pages (pages in current language) and .AllPages (all languages). One possiblity is adding an optional parameter in the frontmatter of the post.
`crosspost: true`
This post would then be added to the .Pages list for all languages disregarding which language it was originally written in.
Another solution is to make a clever query between .Pages and .AllPages and looking for .Params.crosspost to list the "cross posts". This could be achieved without doing any changes to Hugo itself.