Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

Customising the CMS /

Translatable


Reply


3 Posts   1624 Views

Avatar
Beck

Community Member, 23 Posts

2 September 2009 at 12:45am

Edited: 02/09/2009 12:56am

Hi everyone! problem is: i couldn't do Multi-language page or just one language (except english)

I insert to _config.php:

Object::add_extension('SiteTree', 'Translatable');
Translatable::set_default_locale('ru_RU');
Translatable::set_default_lang('ru');

then: dev/build?flush=1

but it doesn't render:
see this page http://roboclean.uz/comments here actually must be in russian but there in english

even i did
i18n::set_default_locale('ru_RU');
i18n::set_default_lang('ru');
but error is: Fatal error: Call to undefined method i18n::set_default_locale() in /home/robouz/public_html/mysite/_config.php on line 27

then did
i10n::set_default_locale('ru_RU');
i10n::set_default_lang('ru');
error:Fatal error: Class 'i10n' not found in /home/robouz/public_html/mysite/_config.php on line 27

2. question is how can i chagne in comment form, website url to email or add extra form(example: Country)

thanks in advance

Avatar
Beck

Community Member, 23 Posts

3 September 2009 at 8:48am

urgent problem. i didn't solve this problem yet

Avatar
Ingo

Forum Moderator, 801 Posts

12 September 2009 at 4:48pm

Uhm, you're using APIs that don't exist (i10n and set_default_locale), what other than an error do you expect?

Please have a look at http://doc.silverstripe.com/doku.php?id=multilingualcontent#switching_languages