From 660bdeea111930641d8350d2efcf1416154d7676 Mon Sep 17 00:00:00 2001 From: Michael M Slusarz Date: Thu, 28 Jan 2010 16:41:04 -0700 Subject: [PATCH] Improved datatree admin output --- horde/admin/datatree.php | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/horde/admin/datatree.php b/horde/admin/datatree.php index 75af77e36..697bce49a 100644 --- a/horde/admin/datatree.php +++ b/horde/admin/datatree.php @@ -43,14 +43,14 @@ if (is_a($roots, 'PEAR_Error')) { } else { foreach ($roots as $root) { $tree->addNode($root, null, $root, 0, false); - $datatree = &DataTree::singleton($driver, array_merge($config, array('group' => $root))); + $datatree = DataTree::singleton($driver, array_merge($config, array('group' => $root))); addTree($root, DATATREE_ROOT); } } if ($show = Horde_Util::getFormData('show')) { list($root, $id) = explode(':', $show); - $datatree = &DataTree::singleton($driver, array_merge($config, array('group' => $root))); + $datatree = DataTree::singleton($driver, array_merge($config, array('group' => $root))); $data = $datatree->getData($id); $attributes = $datatree->getAttributes($id); } @@ -62,8 +62,12 @@ echo '

' . Horde::img('datatree.png') . ' ' . _("DataTree") . $tree->renderTree(); if ($show) { echo '
'; + echo "Data:\n"; ob_start('htmlspecialchars'); print_r($data); + ob_end_flush(); + echo "\nAttributes:\n"; + ob_start('htmlspecialchars'); print_r($attributes); ob_end_flush(); echo '
'; -- 2.11.0