function simplemenu_get_devel in SimpleMenu 5
Return a list of devel module links if the module is enabled and the user has access to this module.
1 call to simplemenu_get_devel()
- simplemenu_get_menu in ./
simplemenu.module - Render an HTML list of links for a given menu.
File
- ./
simplemenu.module, line 216 - Creates a simplemenu.
Code
function simplemenu_get_devel() {
$output = '';
if (variable_get('simplemenu_devel', 0) && module_exists('devel')) {
if (user_access('access devel information')) {
$links[] = l('Devel settings', 'admin/settings/devel', array(
'title' => t('Adjust module settings for devel module'),
));
$links[] = l('Empty cache', 'devel/cache/clear', array(
'title' => t('Clear the database cache tables which store page, menu, node, and variable caches.'),
), drupal_get_destination());
$links[] = l('Phpinfo()', 'admin/logs/status/php');
$links[] = l('Function reference', 'devel/reference', array(
'title' => t('View a list of currently defined user functions with documentation links'),
));
$links[] = l('Reinstall modules', 'devel/reinstall', array(
'title' => t('Re-run hook_install() for a given module'),
));
$links[] = l('Reset menus', 'devel/menu/reset', array(
'title' => t('Resets all menu items to their default settings'),
));
$links[] = l('Variable editor', 'devel/variable', array(
'title' => t('Edit and delete site variables'),
));
$links[] = l('Session viewer', 'devel/session', array(
'title' => t('List the contents of $_SESSION'),
));
if (function_exists('devel_node_access_perm') && user_access(DNA_ACCESS_VIEW)) {
// True only if devel_node_access enabled.
$links[] = l('Node access summary', 'devel/node_access/summary');
}
$output = '<li class="expanded"><a href="' . url('admin/settings/devel') . '">' . t('Devel module') . '</a><ul>';
$output .= '<li class="leaf">' . implode($links, '</li><li class="leaf">') . '</li>';
$output .= '</ul></li>';
}
}
return $output;
}