Unify heads template
[gitphp.git] / include / display.git_heads.php
blob:a/include/display.git_heads.php -> blob:b/include/display.git_heads.php
--- a/include/display.git_heads.php
+++ b/include/display.git_heads.php
@@ -17,26 +17,9 @@
 	$tpl->clear_all_assign();
 	$tpl->assign("project",$project);
 	$tpl->assign("head",$head);
-	$tpl->display("heads_nav.tpl");
-	$tpl->display("heads_header.tpl");
-	$taglist = git_read_refs($projectroot, $project, "refs/heads");
-	if (isset($taglist) && (count($taglist) > 0)) {
-		$alternate = FALSE;
-		foreach ($taglist as $i => $entry) {
-			$tpl->clear_all_assign();
-			if ($alternate)
-				$tpl->assign("class","dark");
-			else
-				$tpl->assign("class","light");
-			$alternate = !$alternate;
-			$tpl->assign("project",$project);
-			$tpl->assign("age",$entry['age']);
-			$tpl->assign("name",$entry['name']);
-			$tpl->display("heads_item.tpl");
-		}
-	}
-	$tpl->clear_all_assign();
-	$tpl->display("heads_footer.tpl");
+	$headlist = git_read_refs($projectroot, $project, "refs/heads");
+	$tpl->assign("headlist",$headlist);
+	$tpl->display("heads.tpl");
 }
 
 ?>

comments