diff --git a/admin/code/LeftAndMain.php b/admin/code/LeftAndMain.php index 087b454f6..1598a3e39 100644 --- a/admin/code/LeftAndMain.php +++ b/admin/code/LeftAndMain.php @@ -1013,7 +1013,8 @@ class LeftAndMain extends Controller implements PermissionProvider { } $link = Controller::join_links($recordController->Link("show"), $record->ID); - $html = LeftAndMain_TreeNode::create($record, $link, $this->isCurrentPage($record))->forTemplate(); + $html = LeftAndMain_TreeNode::create($record, $link, $this->isCurrentPage($record)) + ->forTemplate() . ''; $data[$id] = array( 'html' => $html, diff --git a/admin/templates/Includes/LeftAndMain_TreeNode.ss b/admin/templates/Includes/LeftAndMain_TreeNode.ss index 7e4c8ebf8..c3617f1dd 100644 --- a/admin/templates/Includes/LeftAndMain_TreeNode.ss +++ b/admin/templates/Includes/LeftAndMain_TreeNode.ss @@ -3,4 +3,3 @@   $TreeTitle - diff --git a/model/Hierarchy.php b/model/Hierarchy.php index 654dc09d5..c42b94be5 100644 --- a/model/Hierarchy.php +++ b/model/Hierarchy.php @@ -127,7 +127,7 @@ class Hierarchy extends DataExtension { * * @return string */ - public function getChildrenAsUL($attributes = "", $titleEval = '"
  • " . $child->Title . "
  • "', $extraArg = null, + public function getChildrenAsUL($attributes = "", $titleEval = '"
  • " . $child->Title', $extraArg = null, $limitToMarked = false, $childrenMethod = "AllChildrenIncludingDeleted", $numChildrenMethod = "numChildren", $rootCall = true, $nodeCountThreshold = null, $nodeCountCallback = null) { @@ -170,10 +170,6 @@ class Hierarchy extends DataExtension { } else { $output .= eval("return $titleEval;"); } - $output = trim($output); - if (substr($output, -5) == '
  • ') { - $output = trim(substr($output, 0, -5)); - } $output .= "\n"; $numChildren = $child->$numChildrenMethod();