Welcome Guest, Not a member yet? Register   Sign In
Multi language site with codeigniter and smarty

I read something about the subject. But I could not find anything that you discuss with smarty.

Could you give me some tips? Or tell me how can I do?

Thanks Smile

(This post was last modified: 07-04-2015, 07:45 AM by llebkered.)

There's a thread that might you here: http://forum.codeigniter.com/thread-1551.html

That's not my problem. I already use codeigniter + smarty. I would be interested in the subject of multilingualism.


Anything which needs to be translated into multiple languages should be in a language file. Then, you just detect the language necessary (either via the URL or a user setting in the database or session), and set the language via $this->config->set_item('language', 'user_or_url_language'); The primary concern is to make sure the language is set before loading any language files, so they will all look for the file in the correct language.

Thanks Smile

If you can, reply in this thread http://forum.codeigniter.com/thread-62364.html

(This post was last modified: 07-17-2015, 04:35 AM by StratoKyke.)

I'm trying, but I can not figure out how to pass variables to smarty language.

Normally in php driving just use: echo $this->lang->line('message_key');

But How do I?

EDIT: I fix the problem with an helper:

Theme © iAndrew 2016 - Forum software by © MyBB