Language Class problems. - Printable Version +- CodeIgniter Forums (https://forum.codeigniter.com) +-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20) +--- Forum: Archived Development & Programming (https://forum.codeigniter.com/forumdisplay.php?fid=23) +--- Thread: Language Class problems. (/showthread.php?tid=2099) |
Language Class problems. - El Forum - 07-16-2007 [eluser]Unknown[/eluser] I seem to be having difficulties with the language class. I'm sure I'm doing something wrong, could someone please shed some light? I am creating a site that requires multiple languages. When I use this command: $this->lang->load('myfile', 'english'); (from my controller) it echoes the entire content of "myfile" at the top if the screen. I then use echo $this->lang->line("my_key"); - it echoes nothing at all. 'myfile' is set up like this: myfile_lang.php is located in the system/application/language/english folder. The contents of 'myfile' is simply: $lang['my_key'] = "Hello"; The version of CI that I am using: // CI Version define('APPVER', '1.5.3'); What am I doing wrong here? Language Class problems. - El Forum - 07-16-2007 [eluser]esra[/eluser] Application-specific _lang files should go in application/language/. If you do so, upgrading to new versions of CI is easier because you can replace the system directory to upgrade the framework core. |