DataObjects/I18n.php
[Pman.Core] / DataObjects / I18n.php
index 1cd61f2..0cb720c 100644 (file)
@@ -70,9 +70,17 @@ class Pman_Core_DataObjects_I18n extends DB_DataObject
         }
         $loaded =true;
         $ff= HTML_FlexyFramework::get();
-         
-        // since our opts array changed alot..
-        $opts = empty($ff->Pman_Core_I18N) ? (empty($ff->Pman_I18N) ? array() : $ff->Pman_I18N)  : $ff->Pman_Core_I18N;
+        
+        // BC compatible.. if any of these are set, then we use them as the settings..
+        $opts = array();
+        foreach(array('Pman_Core_I18N', 'Pman_I18N','Pman_I18n') as $pk) {
+            if (isset($ff->$pk)) {
+                //var_dump($pk);
+                $opts=  $ff->$pk;
+                break;
+            }
+        }
+        //print_R($opts);
         
          
        //  var_dump($opts);exit;
@@ -87,6 +95,8 @@ class Pman_Core_DataObjects_I18n extends DB_DataObject
             }
             self::$cfg[$k] = is_array($v) ? $v  : explode(',', $v);
         }
+        //print_R(self::$cfg);
+        
         return self::$cfg;
         
         
@@ -189,9 +199,11 @@ class Pman_Core_DataObjects_I18n extends DB_DataObject
                     $ret = array_merge($ret, array_keys($cfg['add_c']));
                 }
                 
+                
                  
                 
                 $ret[] = '**';
+                //print_r($ret);
                 break;
             
             case 'l':