where is the Problem ? Sometimes i then have the "de" file mixed with the "en" contetn, why does this one act like it acts ? it drives me crazy -.-
Antoher big thing is using the given database table 'lang' fromn the lang docs. How can i use the database ? is there any tutorial ? or any suggestion how i can use the database ?
To start with your last question: the Lang class uses an "extension" to determine in which format the data is, and where to find it. By default, the ".php" extension is used, which in the above example makes that Lang::load('gui') will load the gui.php file.
If you want to load from the database, you need to use the ".db" extension, as in Lang::load('gui.db').
The multiple language saving issue looks like a bug, can you create an issue for it at https://github.com/fuel/core/issues, with a copy of your example, and/or a link to this post?
loads the strings into the "article" group, so you need to use
$helper = Lang::get('article.article' . $id);
This is what we call "dot-notation". In general, all methods in FuelPHP that access multi-dimensional arrays can be accessed this way, which makes it very easy to retrieve values deep in the array structure.
In the above situation, you have an internal multi-dimenstional Lang array containing:
array( 'article' => array( // this is the group 'article32' => array( 'name' => 'Test_2_en', 'description' => 'Test description', ), 'article33' => array( 'name' => 'Test_3_en', 'description' => 'Test 3 description', ), ); );
so another thing is setting the langauge per Lang::load(). It works fine for the set/save workflow. But for the get workflow it seems like it doesn't work. I will will work with Config::set('language' , 'lang'); on each call.
Fuel is designed to have only one active language, normally there is no need to have multiple languages active in the application at the same time.
The only possible exception is when you have a "translation" controller, where you allow the application user to add or modify translations. For which you have to do some additional steps, like you have noticed.
This is one of the things that will change in Fuel v2, where every language has it's own data container, and multiple can be active at the same time. And since language strings are not loaded into the same array, there will not be any concurrency issue (like you have now, where you are forced to use unique group names for the same lang.php file).