(DEPRECATED) For a better CodeIgniter with gettext, use my hook →
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
application
system
.gitignore
LICENSE
README.md
index.php
license.txt

README.md

ci-gettext

CodeIgniter using Gettext if php_gettext extension is enabled or php-gettext library if it is not.

How to install?

  1. Copy ./application/config/gettext.php files and make your changes
  2. Load Gettext library in ./application/config/autoload.php.
  3. Create your language files like so: ./application/language/english/LC_MESSAGES/messages.po
  4. If you have edited index.php, make sure to add lines 322 and 323 to yours.
  5. You're done!

Notes

  1. All you languages folder must contain a LC_MESSAGES folder inside which resides .MO files.
  2. Gettext_helper provided comes with handy functions that you can use instead of default ***gettext($msgid){}***. It comes also with functions providing details about current, default and client's language : (current|default|client)_language.

Licenses

All credits go to their respective owners CodeIgniter & Launchpad and a little bit of the rest for Me :D.