Pages translated only for some languages

Is there any solution for this multilingual scenarios?

  1. I have career subpages and want versions only for defined languages, it’s impossible set job page published in one language and draft for others. When I create job page for non default language, content txt file is created also for default language. How can I manage this?

  2. How can I list subpages only if translation exist (not empty content file which is created automatically for default language)?

Thanks

  1. I think the default language is always created, maybe you have to work with a special field, for example a toggle which sets translated to true (or something like that)

  2. I am doing the following on my article-template:

if(!$page->translation($kirby->language()->code())->exists()) {
	go($kirby->language()->code( . '/error/' . $page->uid());
}

It looks for the translation of the page, if it’s not found, it’ll show the error page. Maybe you can use something like that with a filter in your listing.

But your solution check if language file exist, so for default language it’s not working, Am I right?
It’s possible only throu checking special language field?

Thanks

Instead of adding a custom field, you could check if an important content field like the main text field in the default language (or the other languages) is empty (should be a field that can definitely serve as an indicator if the translation can be regarded as “existing” or not)

Make sense, but custom field give more control. In some cases something like draft, where content is not complete but still not ready for publish. Independent statuses for languages would be perfect, but I understand technical limits.

Thanks to all

Well, yes, of course, I’d always prefer a custom field. But since you asked if there was an alternative…

Hi, I’m using custom field for checking if specific language exist like I mentioned above.
Is it possible hide this pages in pages section for specific language in admin?

For example job page “exist” only in specific language and is listed in career admin pages section only in this language.

Thanks