Beispiel #1
0
 public function load_data($data, $level = 0, $parent = null)
 {
     if (is_string($data)) {
         $sub = trim($data);
         $_component = $sub;
         $_parms = $uri;
         if ($m = Core_Regexps::match_with_results('{^([^\\s]+)\\s+(.+)$}', $sub)) {
             $_component = trim($m[1]);
             $_parms = trim($m[2]);
         }
         if (CMS::component_exists($_component)) {
             $_class = CMS::$component_names[$_component];
             $_classref = Core_Types::reflection_for($_class);
             $sub = $_classref->hasMethod('navigation_tree') ? $_classref->getMethod('navigation_tree')->invokeArgs(NULL, array($_parms, $item)) : false;
         }
         $data = $sub;
     }
     return parent::load_data($data, $level, $parent);
 }
Beispiel #2
0
 public function load_data($data, $level = 0, $parent = null)
 {
     if (is_string($data)) {
         $sub = trim($data);
         $data = $this->load_from_component_by_string($sub);
     }
     return parent::load_data($data, $level, $parent);
 }