Full ELMS Learning Network documentation
function theme_node_add_list
×
Error message
User warning: The following module is missing from the file system: theme/theme. For information about how to fix this, see the documentation page. in _drupal_trigger_error_with_delayed_logging() (line 1156 of /var/www/html/elmsln_community/api.elmsln.org/includes/bootstrap.inc).cis7 node.pages.inc | theme_node_add_list($variables) |
cle7 node.pages.inc | theme_node_add_list($variables) |
elmsmedia7 node.pages.inc | theme_node_add_list($variables) |
icor7 node.pages.inc | theme_node_add_list($variables) |
meedjum_blog7 node.pages.inc | theme_node_add_list($variables) |
mooc7 node.pages.inc | theme_node_add_list($variables) |
Returns HTML for a list of available node types for node creation.
Parameters
$variables: An associative array containing:
- content: An array of content types.
Related topics
1 theme call to theme_node_add_list()
- node_add_page in modules/
node/ node.pages.inc - Page callback: Displays add content links for available content types.
2 string references to the theme hook from theme_node_add_list()
Note: this list is generated by looking for the string for this theme hook, so it may include some references that are not actually using this theme hook.
- node_add_page in modules/
node/ node.pages.inc - Page callback: Displays add content links for available content types.
- node_theme in modules/
node/ node.module - Implements hook_theme().
File
- modules/
node/ node.pages.inc, line 44 - Page callbacks for adding, editing, deleting, and revisions management for content.
Code
function theme_node_add_list($variables) {
$content = $variables['content'];
$output = '';
if ($content) {
$output = '<dl class="node-type-list">';
foreach ($content as $item) {
$output .= '<dt>' . l($item['title'], $item['href'], $item['localized_options']) . '</dt>';
$output .= '<dd>' . filter_xss_admin($item['description']) . '</dd>';
}
$output .= '</dl>';
}
else {
$output = '<p>' . t('You have not created any content types yet. Go to the <a href="@create-content">content type creation page</a> to add a new content type.', array('@create-content' => url('admin/structure/types/add'))) . '</p>';
}
return $output;
}