$this_shell = chop($shells[$i]);
if ($current == $this_shell) {
- echo "<option selected value=$this_shell>$this_shell</option>\n";
+ echo "<option selected=\"selected\" value=$this_shell>$this_shell</option>\n";
} else {
if (! preg_match("/^#/",$this_shell)){
- echo "<option value=$this_shell>$this_shell</option>\n";
+ echo "<option value=\"$this_shell\">$this_shell</option>\n";
}
}
}
echo '<tr '. $HTML->boxGetAltRowStyle($i+1) .'>
<td>'. date(_('Y-m-d H:i'), db_result($res,$i,'rundate')).'</td>
<td>'. $cron_arr[db_result($res,$i,'job')].'</td>
- <td>'. nl2br(db_result($res,$i,'output')).'</td></tr>';
+ <td>'. nl2br(htmlentities(db_result($res,$i,'output'))).'</td></tr>';
}
print '<a name="active">'._('Active Deliveries').':</a>';
-echo $GLOBALS['HTML']->listTableTop($title);
+$seen = false;
$i = 0;
while ($row = db_fetch_array($res)) {
+ if (!$seen) {
+ echo $GLOBALS['HTML']->listTableTop($title);
+ $seen = true;
+ }
echo '
<tr '.$GLOBALS['HTML']->boxGetAltRowStyle($i++).'>
<td> <a href="massmail-del.php?id='.$row['id'].'"></a></td>
';
}
-echo $GLOBALS['HTML']->listTableBottom();
+if ($seen) {
+ echo $GLOBALS['HTML']->listTableBottom();
+} else {
+ echo '<p>' . _('No deliveries active.') . "</p>\n";
+}
site_admin_footer(array());
<?php echo _('Existing Responses:'); ?><?php echo get_canned_responses(); ?>
<!-- Reinhard Spisser: commenting localization, since otherwise it will not work -->
<!--
-<input name="action" type="submit" value="<?php echo _('Edit'); ?>"/>
+<input name="action" type="submit" value="<?php echo _('Edit'); ?>" />
<input name="action" type="submit" value="<?php echo _('Delete'); ?>" />
---->
-<input name="action" type="submit" value="Edit"/>
+-->
+<input name="action" type="submit" value="Edit" />
<input name="action" type="submit" value="Delete" />
<input type="checkbox" name="sure" value="<?php echo _('yes'); ?>" />
<?php echo _('Yes, I\'m sure'); ?>
<?php echo _('Response Text:'); ?><br />
<textarea name="response_text" cols="50" rows="10"></textarea>
<br />
-<input type="hidden" name="action" value="Create">
+<input type="hidden" name="action" value="Create" />
<input type="submit" name="actions" value="<?php echo _('Create'); ?>" />
</form>
_('Active (A)'),
_('Suspended (S)'));
}
-?>
-<?php echo html_build_select_box_from_arrays(
+echo html_build_select_box_from_arrays(
$status_letter, $status_text,'status', $u->getStatus(), false);
?>
</td>
$title[]=_('Name');
$title[]=_('Unix name');
$title[]=_('Operations');
-echo $GLOBALS['HTML']->listTableTop($title);
$i = 0 ;
foreach ($projects as $p) {
+ if ($i == 0) {
+ echo $GLOBALS['HTML']->listTableTop($title);
+ }
print '
<tr '.$GLOBALS['HTML']->boxGetAltRowStyle($i++).'>
<td>'.util_unconvert_htmlspecialchars(htmlspecialchars($p->getPublicName())).'</td>
<td width="40%">'.util_make_link ('/project/admin/?group_id='.$p->getID(),_('[Project Admin]')).'</td>
</tr>
';
-
+ $i++;
}
-echo $GLOBALS['HTML']->listTableBottom();
+if ($i > 0) {
+ echo $GLOBALS['HTML']->listTableBottom();
+} else {
+ echo '<p>'._('This user is not a member of any project.').'</p>';
+}
echo '<br />';
site_admin_footer(array());
forum_header(array('title'=>_('Delete a Message')));
echo '<center>
<form action="'.getStringFromServer('PHP_SELF').'" method="post">
- <h3>' . _('WARNING! You are about to permanently delete a message and all of its followups!!') . '</h3><p>
+ <h3>' . _('WARNING! You are about to permanently delete a message and all of its followups!!') . '</h3>
<p>
<input type="submit" name="ok" value="' . _('Yes') . '" />
<input type="submit" name="cancel" value="' . _('No') . '" />
</td>
<td><input type="text" name="package_name" value="'.db_result($res,$i,'package_name') .'" size="20" maxlength="60" /></td>
- <td>'.frs_show_status_popup ('status_id', db_result($res,$i,'status_id')).'</span></td>
+ <td>'.frs_show_status_popup ('status_id', db_result($res,$i,'status_id')).'</td>
<td><input type="submit" name="submit" value="'._('Update').'" />
<a href="deletepackage.php?package_id='.
$group = group_get_object($group_id);
+if (!isset($feedback)) $feedback = "";
+
if (!$group || !is_object($group)) {
exit_error('Error','Error creating group object');
} else if ($group->isError()) {
?>
-<form name="new_vhost" action="<?php echo getStringFromServer('PHP_SELF').'?group_id='.$group->getID().'&createvhost=1'; ?>" method="post">
+<form name="new_vhost" action="<?php echo getStringFromServer('PHP_SELF').'?group_id='.$group->getID().'&createvhost=1'; ?>" method="post">
<table border="0">
<tr>
<td> <?php echo _('New Virtual Host <em>(e.g. vhost.org)</em>') ?> </td>
function stats_util_sum_array( $sum, $add ) {
+ if (!is_array($sum)) {
+ $sum = array();
+ }
while( list( $key, $val ) = each( $add ) ) {
+ if (!isset($sum[$key])) {
+ $sum[$key] = 0;
+ }
$sum[$key] += $val;
}
return $sum;