Going Global: How to Make Your Site Multilingual
-
Upload
acquia -
Category
Technology
-
view
1.021 -
download
0
Transcript of Going Global: How to Make Your Site Multilingual
Going Global: How to Make Your Site Multilingual
Dave Myburgh Senior Engineer Acquia
Acquia Webinar: 23 July 2013
About me • incRn8 (user/51467) on Drupal.org
• using Drupal since 4.6.5 (7+ years) - second site was multilingual
• still have one 4.7 site live!
• was a freelancer until I started at Acquia almost 2 years ago
• contracted for Bonnier for a year and worked on popsci.com
• jack-of-all-trades: originally a themer and site-builder
• lead dev on acquia.com
• take commands from marketing department, which keeps things
interesting ;)
About me
... and in case you were wondering about the
accent, I'm originally from South Africa
Multilingual Drupal 7
Node (content) translationone node per translation
vs
Entity translation one node for all translations
Multilingual Drupal 7
Node translation Entity translation Only works on nodes Works with any entity
One node per language One entity for ALL languages
Uses core node title "field" Requires Title module
Views language filtering works Required a patch to filter on entity language
XML Sitemap works XML Sitemap could not filter on entity language
Block translation is tricky Bean block module
Multiple menu items per language Single menu item per language
Multilingual Drupal 7
Drupal 8 will use entity translation.
Entity Translation requirements
• Entity Translation http://drupal.org/project/entity_translation
• Entity API http://drupal.org/project/entity
• Title module http://drupal.org/project/title ...replacing node titles with fields
Recommended: • Bean module http://drupal.org/project/bean
Block Entities Aren't Nodes
Multilingual Drupal 7
Demo
Language issues
• menus didn't translate nicely - structure was different anyway
• menublocks only show English menu titles
• breadcrumbs often show English text
• XML Sitemap shows English only
= switch to node translation
Node (content) translation
• i18n module suite
• want to switch all entity translations to nodes
• change content type translation to regular translation
• evaluated how to do it programmatically, but simpler to do it
manually (copy/paste)
• used backup site with ET running to switch languages
• redo url aliases to point to new nodes
• update Views to use content translation language filter
Node (content) translation
• All translatable node types use node translation
• Menublocks in the footer work properly now
• XMLSitemap shows correct language nodes
• Breadcrumbs switch language correctly
So now we have:
Block translation
Still using Bean blocks
So we're running Entity translation module as well as
content translation.
Language switching
• Multiple languages use less real estate in a drop-down
• Language Switcher Dropdown http://drupal.org/project/lang_dropdown
• disable javascript option
• hard to theme, so browsers control much of the output
Q & A
• Entity Translation http://drupal.org/project/entity_translation
• Entity API http://drupal.org/project/entity
• Title module http://drupal.org/project/title
• Bean module http://drupal.org/project/bean
• Localization update https://drupal.org/project/l10n_update
Modules used
Q & A
• Views & Entity translation https://drupal.org/node/
1330332#comment-7360440
• Gabor Hojtsy http://hojtsy.hu/multilingual-drupal7
Useful links
Thanks!