Synology DSM: Multilingual 3rd Party Packages

This is how to detect the language which the Synology DSM ExtJS v3.4 Desktop currently displays “on screen”. In order to integrate 3rd party packages properly with the language currently displayed to the user.

I’d required a DS712+ or DS412+ but got a DS411slim with ARMv5TE CPU, which is quite a toy. Marvell Kirkwood, the Aramada 300 series seems to be quite consumer-orientated in general; The least required for serious Linux is ARMv7 platform — more like the Marvell Armada XP, in order to run Ubuntu for ARM.

Just gave up because Synology doesn’t provide essential DSM documentation or any real developer support. Nothing against closed source-code, but such proprietary Linux distributions are simply too time-consuming to be effective to work with in any work. Also – after being sold consumer-electronics, they didn’t won’t to change it to something more adequate for a web-developer.

function user_lang($username='admin'){
   $json='/usr/syno/etc/preference/'.$username.'/usersettings';
   if(file_exists($json)){
      $obj=json_decode(file_get_contents($json));
      return $obj->Personal->lang;
    }
 }

function user_name(){
   $username='';
   putenv('HTTP_COOKIE='.$_SERVER['HTTP_COOKIE']);
   putenv('REMOTE_ADDR='.$_SERVER['REMOTE_ADDR']);
   exec('/usr/syno/synoman/webman/modules/authenticate.cgi', $username, $retval);
   if($retval==0 && $username!=''){return $username[0];}else{return false;}
}

3 Responses to “Synology DSM: Multilingual 3rd Party Packages”

  1. Terry T. Hernandez says:

    Hello, I’m having a problem with copying large number of files to (or from) my synology box (RS810 , DSM version DSM 4.0-2198).After few minutes of copying files I get error message on my Windows 7 x64 Pro: “Too many files are currently in use”.The problem seems to be with Samba or configuration of samba and it is well documented on this link: https://bugs.launchpad.net/ubuntu/ sour … bug/462172 Can someone help me with this issue.

  2. kpss kitaplar─▒ says:

    I am searching for any skilled writer, lengthy time within this area. Great post!

  3. Eleanore Scharr says:

    Can I simply just say what a comfort to discover someone that really understands what they are discussing on the net. You certainly know how to bring a problem to light and make it important. More people ought to look at this and understand this side of the story. I can’t believe you are not more popular because you definitely possess the gift.