How to set a language to a module

Talk about writing modules and plugins for CMS Made Simple, or about specific core functionality. This board is for PHP programmers that are contributing to CMSMS not for site developers
Post Reply
drizzt
New Member
New Member
Posts: 8
Joined: Thu Feb 14, 2008 10:30 am

How to set a language to a module

Post by drizzt »

Hello,
i would like to know, how to set a language to a module, when a instanciate it this way :

$cge = cms_utils::get_module('CGExtensions');

I use $cge to generate a dropdown field of countries. But i would like to have them translated, as in other modules.

I look in CGExtensions.module.php , i found nothing about setting the language of the current object.


Thanks
User avatar
Dr.CSS
Moderator
Moderator
Posts: 12711
Joined: Thu Mar 09, 2006 5:32 am
Location: Arizona

Re: How to set a language to a module

Post by Dr.CSS »

Not sure how it will work in this instance but most modules Help has lang='en_US' parameters...
drizzt
New Member
New Member
Posts: 8
Joined: Thu Feb 14, 2008 10:30 am

Re: How to set a language to a module

Post by drizzt »

Yes, i know that, but i'm looking for the php way of doing that.
I will try to hardcode the language in the lang function if i find it (ex. $mod->Lang('FR'); ).
Post Reply

Return to “Developers Discussion”