By Gábor Hojtsy , 7 February, 2013

Many of the Drupal 8 core APIs are shaping up now, and as Larry Garfield likes to say "we are still not ready porting Drupal 8 to Drupal 8". Meaning that the new APIs introduced are not used widely at all places where they would be applicable. Views is in core, but not all listings are views, router configuration instead of menu hooks are in core, but most modules use menu hooks, and so on. We of course target the final Drupal 8.0 release to have these conversions done, but we need more help to do them. Let me highlight items that interest me most as the multilingual initiative lead (but most of these rhyme with multi-channel publishing / web-services efforts as well).

Help convert content-like things to content entities

Drupal 8 has a new improved Entity API to manage content entities. What better opportunity to get to know the new content handling APIs than being involved in porting core components to it? Web services and multilingual are both fundamentally in need of a unified handling for content-like stuff in Drupal.

Comments have already been converted to the new entity API (http://drupal.org/node/1778178) which can serve as an example for conversions elsewhere, namely nodes (http://drupal.org/node/1818556), users (http://drupal.org/node/1818570) and so on. See the full list of conversion issues at http://drupal.org/node/1818580. Once these conversions are done, we still need to apply multilingual property handling to do such basic things as editing titles on nodes in different languages (http://drupal.org/node/1498674).

While the existing entity types need conversions, there are also other content-like things in core that need to be converted to entities proper. For example aggregator feeds (http://drupal.org/node/293318) have been converted to content entities but more needs to be worked on. Hands are needed to help with converting menu links (http://drupal.org/node/916388) and custom blocks (http://drupal.org/node/1871772) as well.

Learn Drupal 8 configuration by porting things to the configuration system

The new configuration system in Drupal 8 is great in unifying all configuration elements under one system instead of custom one-off database storages and APIs for configuration.

There is a laundry list of system settings forms to convert to configuration at http://drupal.org/node/1696224 including locale module settings, file system settings, etc. still to be done.

Drupal 8 also comes with configuration entities, which store their data with the configuration system (and are not fieldable). Some of the previously custom coded features such as views, menus (http://drupal.org/node/1814916) and contact form categories (http://drupal.org/node/1588422) have been converted to configuration entities. Others like languages are still to be done (http://drupal.org/node/1754246). Track all related issues at http://drupal.org/node/1802750.

Learn the new configuration schema system by writing schemas for configuration

A configuration schema system was just recently added to core (see http://drupal.org/node/1905070 for documentation and examples). Some configuration files got a schema defined in the initial patch, but there is still more work to be done to adopt this and complete. For example, only some of Views got schemas written, and we need to complete that (http://drupal.org/node/1910606). The meta issue to track and find schema issues is at http://drupal.org/node/1910624.

Why get involved?

I think this is a unique opportunity to (a) get to know Drupal 8 early (b) still have a chance to shape things in Drupal 8 where you find them confusing (instead of bragging about them too late when there is no chance to change) and (c) help Drupal 8 become the great consistent platform we all want it to become. Better web services features and dramatically more extensive multilingual features are also a huge plus!

How to get help if you get stuck?

Most of these issues have someone who got it started and you can find the people who worked on previous complete conversions that I linked to above. Find these people on IRC, get involved in virtual meetings, ask at core mentoring hours. Sometimes all is needed is reviews, help testing or help writing tests.

Thanks for all your contributions!

By Gábor Hojtsy , 28 November, 2012

I've had the pleasure to present the results of the Drupal 8 Multilingual Initiative - great work of numerous highly respected individuals - at the start of this month in Berkeley at BADCamp 2012. The session has some great demo content about where did we get and background information on what is still to be done. We are pretty close with all the essentials but will not be bored for the rest of the Drupal 8 release cycle either to put on more polish and fix the rough edges. Meet us this Friday, the last day before the Drupal 8 feature freeze if you want to get involved!

By Gábor Hojtsy , 13 July, 2012

The content translation problem

One of the great goals of the Drupal 8 Multilingual Initiative (D8MI for short) is to have one unified system for content translation. The basic problem is that with Drupal 7, you have two ways to translate content: copy nodes for different language versions (with the built-in Content translation module) or save different languages under one entity (with the built-in multilingual fields capability). Although the later does not have a user interface in core, the API is there, so well respecting contributed modules need to support both. The reality is that many modules support neither, because node copies are combersome and field language support is painful.

This is both a user and a developer problem. Users need to decide their translation methods up front, and both methods have their advantages and limitations. Node copies allow for best workflow because they have authors, publication status, permissions, core search support, etc. all a given. Field language on the other hand works better with relations (when signing up for nodes, putting nodes into a common menu, etc.) as well as sharing values between translations (product images, non-translated attributes, etc.). The grand plan for Drupal 8 is to figure out a way for a system that marries the advantages of all as possible and have one better configurable system instead of two independent systems. This should make it easier for users and developers alike to work with multilingual entities.

This is an extremely simple idea, yet the implementation is lagging behind enourmously.

By Gábor Hojtsy , 25 April, 2012

I've highlighted some great developments around multilingual Drupal in my Denver core conversation talk (see the slides and video for details on where Drupal 8 multilingual improvements are going or check out the interview with me on Modules Unraveled from last week). First of all, there are some great new developments with each, second these got little publicity if anything, so I wanted to broadcast the good news here too.

Drupal 7 Multilingual Sites book is out

The Drupal 7 Multilingual Sites book is out from Packt Publishing! Jose Reyero (Internationalization module maintainer) was a technical reviewer, and I've been involved with the book as a technical reviewer in parallel (without monetary compensation), so even if you might not recognize the name of the author (Kristen Pol), I can assure you that it is a strong book. It starts off from the basics and reaches as far as it comprehensively can in the small size. It goes through some complex topics like tips and tricks for Views, Panels and SEO, and even includes comprehensive tables for which module to use for translating what. Some topics were cut out due to the size boundaries but you can already read one of those as an article on Kristen's blog on Drupal Commerce localization. The book should be a life-saver for anybody starting out building multilingual Drupal 7 sites and even those who already got started but stumbled into some seemingly unsolvable issues. Admittedly as the book goes into some of the more advanced topics, you'll face note boxes more and more as it references issues where fixes for problems are in the works. Help is always welcome.

Ps. Kristen is happy to donate ruffle copies of the book for your events, see https://twitter.com/#!/kristen_pol/status/193752939515490304

New Translation Management Tool module

While there are relatively good tools to translate content, configuration and the user interface in Drupal, larger scale setups will require more complex translation workflows with queues for people working on translations and integration with outside services and subcontractors for translation. Remember the Translation Management module? Well, that was a bit monolithic solution to this problem, did not integrate with common Drupal components such as Views and Rules and was never fully ported to Drupal 7. There was no community behind it and as the developers stopped working on it, there was no solution for people to look to.

Enter Translation Management Tool (tmgmt) a solution along the Drupal way (TM) to the same problems. It is component based, already integrates with more services and is backed by several companies in Europe. It was bootstrapped earlier this year in Europe and is actively developed ever since. For further icing on the cake, a great project to improve and build on the module was accepted for this year's Google Summer of Code, so we are going to see even more awesomeness coming from there!

Drupal as base implementation in European Union multilingual project

Carsten and Carina from Cocomore held a discussion at Drupalcon Denver incorporating their announcement of the EU funded "MultilingualWeb - Language Technologies" (MultilingualWeb-LT) project for the Drupal community. The project is managed by a W3C Working Group and its goal is "to combine several existing technologies and standards to close gaps in the technical localization chain by better integrating localization service providers and translation technologies". It is not just a standards effort, the initial implementation is going to happen based on Drupal! Yes! We hope to work with this project on Drupal 8 improvements if the timeline allows and they certainly plan to make heavy use of the tmgmt module on Drupal 7 which should lead to more improvements and fixes there.

By Gábor Hojtsy , 13 April, 2012

xjm has a great guide for doing interdiffs using two branches for the original patch and your new changes. I must admit I'm lazier than that, and have a much simpler process for doing interdiffs on patch updates. Of course this only works if you work on one patch at a time. Branches are better when you work on different things and want to keep those things around. With that, here is my simpler interdiff workflow.

By Gábor Hojtsy , 11 April, 2012

I've had the great opportunity to share my experience navigating the waters of Drupal core development at at DrupalCon Denver last month. My talk "Thrown Into a Shark Pond? A Guide for Surviving Core Development and Even Enjoying It" was possibly a little sensationally titled, although every Drupal core developers have their ups and downs and sometimes people do feel like they are in a shark attack. I planned to provide good ways forward from different ways that ideas can be blocked from inception through implementation to getting it into core.

When preparing for the session, I realized I'm going to explain a somewhat complicated tree with different decision points and states. I wanted my session to be a useful and clear explanation and let people focus on tips and tricks instead of piecing together this tree in their head, so I decided to design a handout for the attendees (PDF, 250k). This turned out to be pretty great I think, and I got lots of content feedback from xjm, webchick, Moshe Weitzman, Kieran Lal and even Dries at various stages of drafting it. (Getting it printed on-site was a herculean undertaking, but that is really due to the printing shop services available.) At the end, each attendee got a nice color copy of this that they could bring home (and the leftovers I had were distributed at the new contributors sprint at the end of the conference). After all I decided to not theme the talk or the handouts with sharks, in hopes that the handouts would be much more easily reusable later just as well.

You can also watch the recording of the session below, and download the slides (PDF, 7.8M).

By Gábor Hojtsy , 19 November, 2011

After reviewing language support and translation for many of Drupal's pieces, we arrived at a pretty complex question, building multilingual navigation. The question is especially of importance because we often need to put translated content in menus, and the cross of translation of content and translation of menus can easily get us into the woods. Let's build some simple solutions for different use cases to see how to think of multilingual menus.

By Gábor Hojtsy , 28 September, 2011

I know many of you faced the goal explained above. There are tools of different levels of involvement and there is of course no ready-baked answer to this question, but here is my best take so far for the current two active versions and Drupal 8 in development.

The three areas of Drupal language support

(A) First off, you can run a single language foreign language website without a need for content or configuration translation. Because the Drupal user interface comes in a flavor of English, you'll need to translate that. But all your content and configuration can be entered in your language, so you are fine there.

(B) Second, if you need to mark your content with language information, such as if you are running a multilingual blog, where you post in different languages, but will not translate your posts, you need language assignment with multiple language options.

(C) Finally, if you need to have the same content translated, the same navigation replicated or similar navigation produced for different languages, you need translation for your content and configuration.

The three types of data for Drupal translation

When it comes to translation, Drupal data can be separated to three buckets: (1) User interface (2) Content (3) Configuration. Drupal has very extensive support for user interface translation, I'd say too much support for content translation and usually not so bright support for configuration translation. Let's enumerate what Drupal has on offer for each piece.

By Gábor Hojtsy , 17 June, 2011

As some of you might be aware, a group of talented and very determined people sprinted in Berlin about a month ago just to improve the i18n module for almost a week. A lot of great improvements made it in including tests, translatable contact forms and even some great usability improvements. Jose Reyero and Friederike Schmiedebach have great posts about the sprint.

Before continuing my article series, I wanted to touch quickly on the usability improvements, because my previous piece presented a pretty grim picture of textgroup based translation solutions such as blocks. Well, i18n module is still using that backend, but the new user interface improvements will make the translation process much more transparent and a lot easier to work with when managing Drupal configuration.

By Gábor Hojtsy , 8 June, 2011

My last post where I've explained how Internationalization module re-implements some of Field API and where it does not do that it misses crucial functionality did not get much discussion. Therefore I decided to turn the key point at the end to the center of discussion: that either Drupal core will do fields for all user input (content and configuration alike, all through form your site name to your views empty text), or i18n module needs to do it in contrib. There is a clear need for input widgets, validators, permission handling, storage and output formatters and rendering used consistently. If it is not done by core, it will keep being a bolted-on half-failing approach despite best efforts in contrib. Please discuss at http://groups.drupal.org/node/154434

The other important post that we need your input on is about removing all UI strings from code. There are various issues with having them in code, while there are also various disadvantages to removing them from there. There are performance, translatability and even user experience concerns involved. This post is already getting some discussion, but we need much more. This could be a huge, fundamental change, so all your input is welcome. Don't say we did not ask you. Please discuss at http://groups.drupal.org/node/154394

Your input helps shape Drupal 8 and how Drupal supports building multilingual sites for years to come. Have your voice heard now!