problem whith language class |
[eluser]ahmedi[/eluser]
Hello I have a small problem when using languge in controller : I load the language like this in function in my controller : $this->lang->load('infos','french'); and the problems is that the file is sent to output , yout can see the result at my site : http://www.valuatemywebsite.com/website/...ite/calcul thanks for any help
[eluser]InsiteFX[/eluser]
Post your code so that we can see whats going on! Enjoy InsiteFX
[eluser]ahmedi[/eluser]
this is my code inside the controller : //============================================== // load language file //============================================== $this->lang->load('infos','french'); $messages['title'] = $this->lang->line('infos_title'); $this->load->View('header_view'); $this->load->View('allrank_view',$r); $this->load->View('footer_view');
[eluser]ahmedi[/eluser]
for me , it seems that calling to $this->lang->load('infos','french'); it calls to an echo function thank you for your answers
[eluser]InsiteFX[/eluser]
You must be doing something wrong in the rest of your code. Check out the user guide here: Language Class Enjoy InsiteFX
[eluser]ahmedi[/eluser]
I'm starting with CI, but i'm based on the online documentation, so i did exactly what is said in the link you send: What i'm dowing is that i make folder french in application/language , and in this folder i put the file infos_lang.php and in the controller i call laod this by use $this->lang->load('filename','language'); and this line produce immediatly and echo outptut. thanks for your answers
[eluser]cahva[/eluser]
If it prints the language file as is, you must be missing starting php tag <?php as the file is not parsed by PHP.
[eluser]ahmedi[/eluser]
thanks you all yes my problem is that i have forgotten the php tags <?php |
Welcome Guest, Not a member yet? Register Sign In |