News Feed
Sections




News Archive
Looking for more information on how to do PHP the right way? Check out PHP: The Right Way

SitePoint PHP Blog:
Managing Gettext Translations on Shared Hosting
February 11, 2014 @ 13:09:19

On the SitePoint PHP blog today Aurelio De Rosa makes some recommendations about handing gettext translations on shared hosting. The problem with shared hosting is the need to reset the web server (Apache) to get it to read the updated translation files. His workarounds uses an external script that can dynamically pull in the latest translations without the restart.`

For serious translations we can use Gettext. This approach enables us to have different files for every targeted language which helps in maintaining separation between the business logic, the presentation layer, and the translations (which we can see as an add-on of the presentation layer). With Gettext, we can parallelize the process because while we're working on some features of the website, translators can still work on translations using software like gettext functionality to set the current language and extract a "HELLO_WORLD" string. He then moves on to the use of the Audero Shared Gettext library. This library creates a "mirror" of the translation file requested and forces those updates into the current domain. Code examples of its use are included showing a basic pull and merge process.

0 comments voice your opinion now!
gettext tranlsation dynamic loading webserver shared hosting tutorial

Link: http://www.sitepoint.com/managing-gettext-translations-shared-hosting

blog comments powered by Disqus

Similar Posts

Zend Developer Zone: Working with RAR, LZF and BZ2 Compression Formats in PHP

Rob Allen's Blog: Tutorial Notes - Zend_Auth in French & Using Oracle

Sephiroth.it: PHP5 - a big failure?

Cats Who Code: Sending SMS with PHP and TextMagic: An A to Z guide

PHPBuilder.com.au: Executing queries with phpMyAdmin


Community Events

Don't see your event here?
Let us know!


configure release application example introduction symfony2 part2 series interview framework api library php7 performance conference voicesoftheelephpant opinion laravel podcast community

All content copyright, 2015 PHPDeveloper.org :: info@phpdeveloper.org - Powered by the Solar PHP Framework