Experimental project

This is a sandbox project, which contains experimental code for developer use only.

A module that extends the generate content capabilities of Devel to the multilingual arena. It does not affect the current capabilities of the Devel module.

Use Case
Your boss decides that they want the new site you are working on to go international. After explaining to the boss that you want good translations (not Google translate, etc.) for the content, and knowing about Drupal's modules to manage content translation, this
should not be too hard -- but, it sure would be nice to have some dummy content for other locales to work with, just to make sure that things look right (i.e, direction, layout). This module will generate that content for you.

Versions
The alpha1 version (mlgeneratev2)of this project allows limited text/word generation capabilities, which can be pasted from the front page where it is output to any page where multilingual content/menus/vocabularies are desired. It does not handle directionality (ltr/rtl) dynamically -- this depends on the locale for your site. Cut/paste to a site multilingual site using the Localization (l10n) module should work correctly.

How to install this project with Git
To install from the sandbox, clone the contents of this repo to your modules directory (e.g., sites/default/modules). This process assumes you are currently in the directory where you want to install it:

> git clone fejn@git.drupal.org:sandbox/fejn/2183185.git mlgenerate

Enable the mlgenerate module.

Generate content
Accelerate development of your site or module by quickly generating:

  • Content types(nodes)
  • Menus
  • Taxonomies
  • Terms/vocabularies
  • Users

for the following languages:

  • Chinese
  • Japanese
  • Arabic
  • Hebrew
  • Korean

for the following languages/character sets:

  • Greek
  • Hindi (Devanagari)
  • Cyrillic
  • Arabic
  • Hebrew
  • Chinese
  • Japanese
  • Hangul (Korean)
  • Thai
  • Lao
  • Vietnamese

for the following content formats:

  • Paragraph (default for most content types)
  • Word (default for Menus/Taxonomies)
  • Character string

A developer can generate content for language X without having to be fluent in that language. As always, a basic familiarity with the language may help here. No translation capability is intended for this module.

From drush:
drush mlgen --lang "Chinese" --type "paragraph" --num 5
This command would generate 5 paragraphs worth of Chinese (Lorem ipsum) text.

Enhancements
The alpha2 version (mlgenerate) will add some enhancements to make it easier to use and maintain:

  • TBD - More character sets/transliteration
  • TBD - More direct integration with devel_generate
  • TBD - jQuery interface to content generators
  • TBD - Mark devel_generate produced string strings as 'translatable' as well as 'generated'
  • TBD - Allow selection of 'source' locale(default to current) & 'target' locale
  • TBD - Work properly based on locale selected
  • TBD - Drush integration

Dependencies
This module depends on devel - in particular, devel_generate. requires drush to use it from the command line.

Project information