Stack Exchange Network

Stack Exchange network consists of 175 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange
The results are in! See what nearly 90,000 developers picked as their most loved, dreaded, and desired coding languages and more in the 2019 Developer Survey.

New answers tagged

-1

Awesome code, nice and clean, work perfectly. Thanks To use the translation saved: $translated = $this->t('English text', [], ['langcode' => 'es']);


0

The example above for hook_toolbar is almost perfect. I fixed it, see code below. You just have to remove the span on the Language : EN then the click functionality works perfectly. see my code: /** * Implements hook_toolbar(). */ function examplemodule_toolbar() { // Get languages, get current route. $current_language = \Drupal::languageManager()-&...


2

To translate action labels install the core module Actions and go to /admin/config/regional/config-translation/action. Actions are config entities, which you can translate in an exported config as well, if you don't want to install the UI option.


-2

for D7 there is entity_translation_unified_form it is the best one that I have found https://www.drupal.org/project/entity_translation_unified_form


1

Drupal has very advanced Multi-lingual capabilities, so it's safe to assume that you can configure your site according to your needs. You just have to learn a bit about Drupal multilingual fundamentals and see how your needs fit in there. It seems your question is about how languages are selected and displayed, and not about Interface translation. You ...


Top 50 recent answers are included