Automatically fetching translations
Hi!
In D5, we introduced Autolocale module, enabling users to import translations after enabling module / during installation. However, this had few caveats, as timeouts on cheap shared hosts, etc.
In D6, Autolocale is built-in core, using batch API and just works very well.
What do you think next step should be? From my point of view:
"Let Drupal automatically fetch translations from a server".
Imagine an user, enabling a module. Drupal polls Drupal.org (or something else), downloads a translation, imports it. No need to download any package, packages for modules will be smaller.
This could be done for installer and/or contribs.
What do you think and how do you think we can do this?
Just my $0.02:
- Installer is a great place for this, contrib may not be (Translations are already packed with contribs)
- Gabor mentioned (at DrupalCon in Boston) that it may be done using Localization client. Is it wise? Any other approaches?
- I can imagine a very easy implementation using curl()/fopen()/xmlrpc() (having a failback) to query Drupal.org/... for a translation, download it, extract (how to do this without Archive/Tar.php?) and import.
Please post your ideas so we can eventually get this to D7 :-)

Comments
First, comments to the initial post:
xmlrpc(), at least if importing a few strings at a time (per the above). If we're importing entire core/module translations, it might be better to usecurl()or some such and fetching regular PO-files.fopen()on remote files should not be assumed to be allowed/possible to use on a given server, as it could easily be disabled for security reasons withallow_url_fopen(one should always be wary of opening remote files). Also, if we're fetching text/plain PO-files, we wouldn't need Archive_Tar to handle the downloads.Second, my own thoughts:
--
Frederik 'Freso' S. Olesen