I've passed the last hour trying to find information on how to change the language of my opencart page, without changing it forever.

Basically, i know everything about the language packs, and creating your language, but i need to know how a custommer on the page can directly chose his language.

I've been looking around to find a way to change the language directly on the page, but it seems nothing is set in stone, just as if it was already there. Although, i did look a the demo pretty solid and haven't seen flags or language places.

(Here, i am not talking about going in the backend and to change the language, but more like the client way to chose his language he wants !)

If somone knows the "url" or the code i need to input in order to change the language, i would be very happy !

Thanks !

有帮助吗?

解决方案

This is pretty easy to do, though it's not as simple as a URL by default. You need toPOST the relevant language code to the module/language controller to change it. The files you need to look at are

catalog/controller/module/language.php

and

catalog/view/theme/default/template/module/language.tpl

其他提示

If your language is enabled in the admin section, you should see the language selector in the header at run time. I do.

许可以下: CC-BY-SA归因
不隶属于 StackOverflow
scroll top