node_type_get_types

  1. drupal
    1. 8
    2. 7
Versions
7 – 8 node_type_get_types()

Returns a list of all the available node types.

This list can include types that are queued for addition or deletion. See _node_types_build() for details.

Return value

An array of node types, as objects, keyed by the type.

See also

node_type_get_type()

▾ 20 functions call node_type_get_types()

CommentFieldsTest::testCommentDefaultFields in modules/comment/comment.test
Tests that the default 'comment_body' field is correctly added.
comment_field_extra_fields in modules/comment/comment.module
Implements hook_field_extra_fields().
comment_forms in modules/comment/comment.module
Implements hook_forms().
comment_modules_enabled in modules/comment/comment.install
Implements hook_modules_enabled().
comment_uninstall in modules/comment/comment.install
Implements hook_uninstall().
forum_enable in modules/forum/forum.install
Implements hook_enable().
hook_field_extra_fields_alter in modules/field/field.api.php
Alter "pseudo-field" components on fieldable entities.
locale_uninstall in modules/locale/locale.install
Implements hook_uninstall().
NodeTypeTestCase::testNodeTypeGetFunctions in modules/node/node.test
Ensure that node type functions (node_type_get_*) work correctly.
NodeTypeTestCase::testNodeTypeStatus in modules/node/node.test
Test that node_types_rebuild() correctly handles the 'disabled' flag.
node_add in modules/node/node.pages.inc
Returns a node submission form.
node_block_list_alter in modules/node/node.module
Implements hook_block_list_alter().
node_field_extra_fields in modules/node/node.module
Implements hook_field_extra_fields().
node_forms in modules/node/node.module
Implements hook_forms(). All node forms share the same form handler.
node_menu in modules/node/node.module
Implements hook_menu().
node_overview_types in modules/node/content_types.inc
Displays the content type admin overview page.
node_permissions_get_configured_types in modules/node/node.module
Returns an array of node types that should be managed by permissions.
simpletest_example_install in examples/simpletest_example/simpletest_example.install
Implements hook_install().
simpletest_example_update_7001 in examples/simpletest_example/simpletest_example.install
Adds a body field to the simpletest_example node type.
_node_add_access in modules/node/node.module

Code

modules/node/node.module, line 384

<?php
function node_type_get_types() {
  return _node_types_build()->types;
}
?>