W3cubDocs

/Drupal 8

Information types

Types of information in Drupal.

Drupal has several distinct types of information, each with its own methods for storage and retrieval:

  • Content: Information meant to be displayed on your site: articles, basic pages, images, files, custom blocks, etc. Content is stored and accessed using Entities.
  • Session: Information about individual users' interactions with the site, such as whether they are logged in. This is really "state" information, but it is not stored the same way so it's a separate type here. Session information is available from the Request object. The session implements \Symfony\Component\HttpFoundation\Session\SessionInterface.
  • State: Information of a temporary nature, generally machine-generated and not human-edited, about the current state of your site. Examples: the time when Cron was last run, whether node access permissions need rebuilding, etc. See the State API topic for more information.
  • Configuration: Information about your site that is generally (or at least can be) human-edited, but is not Content, and is meant to be relatively permanent. Examples: the name of your site, the content types and views you have defined, etc. See the Configuration API topic for more information.

See also

Cache API

Internationalization

File

core/core.api.php, line 1185
Documentation landing page and topics, plus core library hooks.

© 2001–2016 by the original authors
Licensed under the GNU General Public License, version 2 and later.
Drupal is a registered trademark of Dries Buytaert.
https://api.drupal.org/api/drupal/core!core.api.php/group/info_types/8.1.x