3 * Site Admin: Trove Admin: browse entire Trove tree
5 * Copyright 1999-2001 (c) VA Linux Systems
9 * This file is part of GForge.
11 * GForge is free software; you can redistribute it and/or modify
12 * it under the terms of the GNU General Public License as published by
13 * the Free Software Foundation; either version 2 of the License, or
14 * (at your option) any later version.
16 * GForge is distributed in the hope that it will be useful,
17 * but WITHOUT ANY WARRANTY; without even the implied warranty of
18 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
19 * GNU General Public License for more details.
21 * You should have received a copy of the GNU General Public License
22 * along with GForge; if not, write to the Free Software
23 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
27 require_once('../../env.inc.php');
28 require_once $gfwww.'include/pre.php';
29 require_once $gfwww.'include/trove.php';
30 require_once $gfwww.'admin/admin_utils.php';
32 // print current node, then all subnodes
33 function printnode ($nodeid,$text) {
36 for ($i=0;$i<$GLOBALS['depth'];$i++) {
37 print " ";
40 print html_image('ic/cfolder15.png','15','13',array());
41 print (' '.$text." ");
43 print ('<a href="trove_cat_add.php?parent_trove_cat_id='.$nodeid.'">['._('Add').']</a> ');
45 print ('<a href="trove_cat_edit.php?trove_cat_id='.$nodeid.'">['._('Edit').']</a> ');
46 print ('<a href="trove_cat_add.php?parent_trove_cat_id='.$nodeid.'">['._('Add').']</a> ');
47 print (help_button('trove_cat',$nodeid)."\n");
51 $res_child = db_query("
52 SELECT trove_cat_id,fullname FROM trove_cat
53 WHERE parent='$nodeid'
56 while ($row_child = db_fetch_array($res_child)) {
57 printnode($row_child["trove_cat_id"],$row_child["fullname"]);
62 // ########################################################
64 site_admin_header(array('title'=>_('Site Admin: Trove - Category List')));
68 <h3><?php echo _('Browse Trove Tree'); ?></h3>
74 site_admin_footer(array());
78 // c-file-style: "bsd"