CodeIgniter Forums
lang() third parameter: bug or feature? - Printable Version

+- CodeIgniter Forums (https://forum.codeigniter.com)
+-- Forum: CodeIgniter 4 (https://forum.codeigniter.com/forumdisplay.php?fid=28)
+--- Forum: CodeIgniter 4 Support (https://forum.codeigniter.com/forumdisplay.php?fid=30)
+--- Thread: lang() third parameter: bug or feature? (/showthread.php?tid=75172)



lang() third parameter: bug or feature? - ARAmiss - 01-04-2020

Hello.
If i use this once:
PHP Code:
lang('some_file.some_string', [], 'fr'); 

This will result all next:
PHP Code:
lang('some_another_file.some_another_string'); 
will show last used locale stringĀ as if we had done so:
PHP Code:
lang('some_another_file.some_another_string', [], 'fr'); 


It's ok?


RE: lang() third parameter: bug or feature? - HardyW - 04-15-2020

At least this behaviour is not documented. I just ran into the same issue. I think that this is a bug.