function theme_spam_admin_overview in Spam 6
Same name and namespace in other branches
- 5.3 spam.module \theme_spam_admin_overview()
Theme spam administration overview.
File
- ./
spam.module, line 1427 - Spam module, v3 Copyright(c) 2006-2008 Jeremy Andrews <jeremy@tag1consulting.com>. All rights reserved.
Code
function theme_spam_admin_overview($form) {
// Overview table:
$header = array(
theme('table_select_header_cell'),
t('Type'),
t('Title'),
t('Score'),
t('Status'),
t('IP'),
t('Feedback'),
);
$output .= drupal_render($form['options']);
if (isset($form['title']) && is_array($form['title'])) {
foreach (element_children($form['title']) as $key) {
$row = array();
$row[] = drupal_render($form['spam'][$key]);
$row[] = drupal_render($form['content_type'][$key]);
$row[] = drupal_render($form['title'][$key]);
$row[] = drupal_render($form['score'][$key]);
$row[] = drupal_render($form['status'][$key]);
$row[] = drupal_render($form['hostname'][$key]);
$row[] = drupal_render($form['feedback'][$key]);
$rows[] = $row;
}
}
else {
$rows[] = array(
array(
'data' => t('No spam content found.'),
'colspan' => '7',
),
);
}
$output .= theme('table', $header, $rows);
if ($form['pager']['#value']) {
$output .= drupal_render($form['pager']);
}
$output .= drupal_render($form);
return $output;
}