aboutsummaryrefslogtreecommitdiffstats
path: root/admin/group_list.php
diff options
context:
space:
mode:
authorrvelices <rv-github@modusoptimus.com>2008-03-11 01:51:47 +0000
committerrvelices <rv-github@modusoptimus.com>2008-03-11 01:51:47 +0000
commit62e55bc595f682da05914cc2949454d58a05e368 (patch)
treee51f710bd79dea4a251caca41134d536d01107b5 /admin/group_list.php
parentff19a8f1cd624eae602b64895ce92bdaa7789d69 (diff)
group_list, group_perm and site_manager go smarty
git-svn-id: http://piwigo.org/svn/trunk@2273 68402e56-0260-453c-a942-63ccdbb3a9ee
Diffstat (limited to '')
-rw-r--r--admin/group_list.php16
1 files changed, 7 insertions, 9 deletions
diff --git a/admin/group_list.php b/admin/group_list.php
index 2d8bbfbee..c6a8ecf36 100644
--- a/admin/group_list.php
+++ b/admin/group_list.php
@@ -2,7 +2,7 @@
// +-----------------------------------------------------------------------+
// | PhpWebGallery - a PHP based picture gallery |
// | Copyright (C) 2002-2003 Pierrick LE GALL - pierrick@phpwebgallery.net |
-// | Copyright (C) 2003-2007 PhpWebGallery Team - http://phpwebgallery.net |
+// | Copyright (C) 2003-2008 PhpWebGallery Team - http://phpwebgallery.net |
// +-----------------------------------------------------------------------+
// | file : $Id$
// | last update : $Date$
@@ -154,10 +154,10 @@ UPDATE '.GROUPS_TABLE.'
$template->set_filenames(array('group_list' => 'admin/group_list.tpl'));
-$template->assign_vars(
+$template->assign(
array(
- 'F_ADD_ACTION' => PHPWG_ROOT_PATH.'admin.php?page=group_list',
- 'U_HELP' => PHPWG_ROOT_PATH.'popuphelp.php?page=group_list',
+ 'F_ADD_ACTION' => get_root_url().'admin.php?page=group_list',
+ 'U_HELP' => get_root_url().'popuphelp.php?page=group_list',
)
);
@@ -172,13 +172,12 @@ SELECT id, name, is_default
;';
$result = pwg_query($query);
-$admin_url = PHPWG_ROOT_PATH.'admin.php?page=';
+$admin_url = get_root_url().'admin.php?page=';
$perm_url = $admin_url.'group_perm&amp;group_id=';
$del_url = $admin_url.'group_list&amp;delete=';
$members_url = $admin_url.'user_list&amp;group=';
$toggle_is_default_url = $admin_url.'group_list&amp;toggle_is_default=';
-$num = 0;
while ($row = mysql_fetch_array($result))
{
$query = '
@@ -188,10 +187,9 @@ SELECT COUNT(*)
;';
list($counter) = mysql_fetch_row(pwg_query($query));
- $template->assign_block_vars(
- 'group',
+ $template->append(
+ 'groups',
array(
- 'CLASS' => ($num++ % 2 == 1) ? 'row2' : 'row1',
'NAME' => $row['name'],
'IS_DEFAULT' => (get_boolean($row['is_default']) ? ' ['.l10n('is_default_group').']' : ''),
'MEMBERS' => l10n_dec('%d member', '%d members', $counter),