silverstripe-archive / silverstripe-mobile

Mobile support module for SilverStripe CMS
http://silverstripe.org/mobile/
BSD 3-Clause "New" or "Revised" License
36 stars 36 forks source link

Mobile module problem when using Translatable module and non-default locale #29

Open sasmk opened 12 years ago

sasmk commented 12 years ago

When using the mobile module in combination with the translatable module (https://github.com/silverstripe/silverstripe-translatable) the mobile theme set in the admin backend does not get loaded when using a non-default locale based on ?locale=... parameter.

I.e. when default locale is set to "en_US" and a translation "de_AT" exists, the mobile theme is not loaded. Instead, the default theme is shown.

E.g.

http://server/home -> default theme is loaded, with default locale is set to en_US http://server/home?locale=de_AT -> ALSO default theme is loaded

Translated pages exist and work correctly when not in mobile mode.

C10ne commented 11 years ago

It's not SilverStripe Mobile issue. You need to create translation of site Configuration, and set the mobile options for selected locale.

rjlopes commented 10 years ago

How do you do that? I don't know which file to extend...

C10ne commented 10 years ago

Sorry for the late reply, You need to extend site config, as: Object::add_extension('SiteConfig', 'Translatable'); And then create the translation in "Settings" menu of the CMS.