function _systeminfo_admin_drupal_modules in System Information 6.3
Same name and namespace in other branches
- 7.3 systeminfo.admin.drupal.inc \_systeminfo_admin_drupal_modules()
1 call to _systeminfo_admin_drupal_modules()
- systeminfo_admin_drupal in ./
systeminfo.admin.drupal.inc - Menu callback; displays the Drupal page.
File
- ./
systeminfo.admin.drupal.inc, line 137 - Admin Drupal page callbacks for the systeminfo module.
Code
function _systeminfo_admin_drupal_modules() {
$sort = variable_get('systeminfo_drupal_modules_sort', 'name');
$header = array();
$header[] = t('Name');
$header[] = t('Version');
$header[] = t('Date stamp');
$header[] = t('Filename');
$header[] = t('Schema');
$header[] = t('Weight');
$rows = array();
foreach (module_list() as $module) {
$module_system = db_fetch_object(db_query('SELECT name, filename, schema_version, weight, info FROM {system} WHERE type = "module" AND name = "%s"', $module));
$module_info = unserialize($module_system->info);
$row = array();
$row[] = $module_info['name'];
$row[] = $module_info['version'];
$row[] = isset($module_info['datestamp']) ? format_date($module_info['datestamp'], 'small') : '';
$row[] = $module_system->filename;
$row[] = $module_system->schema_version;
$row[] = $module_system->weight;
$key = $sort == 'name' ? $module_info['name'] : $module_system->filename;
$rows[$key] = $row;
}
if ($sort == 'name' || $sort == 'filename') {
ksort($rows);
}
return theme('table', $header, $rows, array(
'class' => 'systeminfo',
));
}