How do you handle multilingual content when using plone.app.multlingual in some controlpanel options?

plone.app.multilingual can handle content types translations: but some options in controlpanel that would be different in a website with multiple languages won't be translated since it's not a content type. Examples:

http://localhost:8080/Plone/@@mail-controlpanel

http://localhost:8080/Plone/@@site-controlpanel

http://localhost:8080/Plone/@@social-controlpanel

How would you handle this situation?

In our cases, both the Social Media Settings and the email settings use to be the same, so no problem on that side.

Regarding the site title, the viewlet that shows the title follows the INavigationRoot changes made some time ago, so the Title of the site comes from the title of the relevant language root folder. You can check on demo.plone.org how the Site Title contains the name of the language that comes from the title of the relevant language folder.

In case you want to customize the email settings or the social media settings, you can use something like what lineage.registry makes with a proxy-access to the registry in lineage based sites.

1 Like

And also lineage.controlpanels

Don't know the impacts of using collective.lineage in my case. It seems overkill:

Lineage can be used within a large organization to manage multiple microsites

It's not exactly multiple microsites, it's just one but multilingual, but plone.app.multilingual doesn't translate controlpanel options (only content-types).

But I think I'm out of luck in this case.

I meant that you can use the same approach. As far as I see, lineage.registry just has 2 event subscribers fired when a new IChildSite (an interface added by lineage) is added or removed from an item. In those subscribers it just adds the local registry: https://github.com/collective/lineage.registry/blob/master/src/lineage/registry/utils.py#L7

I was suggesting that you can reuse that idea in case you are not using lineage directly.

2 Likes

This package provides a plone.app.registry for Lineage child sites. It adds a local component with a layered-/proxy-registry.

So, the idea would be:

This package provides a plone.app.registry for Root Language folders. It adds a local component with a layered-/proxy-registry.

Indeed, interesting idea. Sorry I didn't grasp it in the first place. The suggestion indeed seems promising. Thanks!

1 Like

I might be misunderstanding what you are asking, it is probably not this:

  1. I add a site with two languages, enable 'Show language flags ' (and maybe use cookie always and use cookie for manual override.
  2. I go to the mail control panel, it shows in Norwegian
  3. I click on the english flag
  4. I got to the mail control panel‚ it shows in english.

If I misunderstand: Lineage control panels should work in your case, after installing it you probably have to adjust the url manually, probably like http://mysite.com/en/@@mail-controlpanel