I18n.php
[Pman.Core] / I18n.php
index 45c5dc4..d7bb6b2 100644 (file)
--- a/I18n.php
+++ b/I18n.php
@@ -195,7 +195,7 @@ class Pman_Core_i18N extends Pman
                 'm' => $this->objToList('m', new I18Nv2_Currency($rlang, 'UTF-8'))
             );
         }
-        echo '<PRE>';print_r($ar);
+        //echo '<PRE>';print_r($ar);
         header('Content-type: text/javascript');
         echo 'Pman.I18n.Data = ' .  json_encode($ar);
         exit;
@@ -206,14 +206,19 @@ class Pman_Core_i18N extends Pman
     function objToList($type, $obj) {
         $ret = array();
         
-        
-        
+         
         foreach($this->cfg[$type] as $k) {
+            $sub = false;
             if (strpos($k, '_') !== false) {
-                $k = array_shift(explode('_', $k));
+                $bits = explode('_', $k);
+                $k = array_shift($bits);
+                $sub = array_shift($bits);
             }
             $v = $k == '**' ? 'Other' : $obj->getName($k);
             
+            if ($sub) {
+                $v .= ' ('.$sub.')';
+            }
             
             $ret[] = array(
                 'code'=>   $type=='l' ? strtolower($k) : strtoupper($k),