[owncloud-devel] Replacement for OC_L10N::forceLanguage

Josef Meile jmeile at hotmail.com
Sat Dec 12 11:35:29 GMT 2015


Dear list

 

My app: AgreeDisclaimer got broken with Owncloud 8.2.1 because the static
function: "OC_L10N::forceLanguage" was removed:

https://github.com/owncloud/core/commit/6b53f7c40e8bbaecfa20a3b19b3164e33290
3f59

 

I agree that static functions are ugly, but before there wasn't any other
way of achieving this.

 

I still need to force owncloud's language to a predefined set of languages
on my app. I do this in my app:

$container = $this->getContainer();

$server = $container->getServer();

$this->l10n = $server->getL10N($this->appName, $language);

 

However, it will set only the language for the application, but the rest of
ownCloud will use the browser preferred language. How can I force the
language for ownCloud?

 

Thanks in advanced.

 

Best regards

Josef

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.owncloud.org/pipermail/devel/attachments/20151212/b79ede4e/attachment.html>


More information about the Devel mailing list