forked from craigk5n/webcalendar
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathgroups.php
38 lines (32 loc) · 1.06 KB
/
groups.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
<?php // $Id: groups.php,v 1.29 2009/11/22 16:47:45 bbannon Exp $
defined ( '_ISVALID' ) or die ( 'You cannot access this file directly!' );
$count = $lastrow = 0;
$newGroupStr = translate ( 'Add New Group' );
$targetStr = 'target="grpiframe" onclick="showFrame( \'grpiframe\' );">';
echo '
<a name="tabgroups"></a>
<div id="tabscontent_groups">
<a title="' . $newGroupStr . '" href="group_edit.php"' . $targetStr
. $newGroupStr . '</a><br />';
$res = dbi_execute ( 'SELECT cal_group_id, cal_name FROM webcal_group
ORDER BY cal_name' );
if ( $res ) {
while ( $row = dbi_fetch_row ( $res ) ) {
echo ( $count == 0 ? '
<ul>' : '' ) . '
<li><a title="' . $row[1] . '" href="group_edit.php?id=' . $row[0] . '"'
. $targetStr . $row[1] . '</a></li>';
$count++;
$lastrow = $row[0];
}
if ( $count > 0 )
echo '
</ul>';
dbi_free_result ( $res );
}
echo '
<iframe src="group_edit.php?id=' . $lastrow
. '" name="grpiframe" id="grpiframe" style="width: 90%; border: 0; '
. 'height: 325px;"></iframe>
</div>';
?>