[[planning-data-types]]
=== Concept: Content Entities and Fields

[role="summary"]
Overview of content entities and fields.

(((Entity,overview)))
(((Taxonomy term,overview)))
(((Vocabulary,overview)))
(((Content,entity type)))
(((Entity type,overview)))
(((Entity subtype,overview)))
(((Block,entity type)))
(((Comment entity type,overview)))
(((Contact form entity type,overview)))
(((Form entity type,overview)))
(((Content entity type,overview)))
(((Custom block,entity type)))
(((Field,overview)))
(((User profile entity type,overview)))
(((Module,Comment)))
(((Module,Contact)))
(((Module,Taxonomy)))
(((Module,User)))
(((Module,Node)))
(((Module,Custom Block)))
(((Module,File)))
(((Comment module,entity type)))
(((Contact module,entity type)))
(((Custom block module,entity type)))
(((Node module,entity type)))
(((Taxonomy module,entity type)))
(((User module,entity type)))
(((File module,entity type)))

==== Was man wissen sollte

* <<understanding-data>>
* <<understanding-modules>>

==== What is a content entity?

A _content entity_ (or more commonly, _entity_) is an item of content data,
which can consist of text, HTML markup, images, attached files, and other data
that is intended to be displayed to site visitors. Content entities can be
defined by the core software or by modules.

Content entities are grouped into _entity types_, which have different purposes
and are displayed in very different ways on the site. Most entity
types are also divided into _entity sub-types_, which are divisions within an
entity type to allow for smaller variations in how the entities are used and
displayed. Here is a table of some common content entity types:

[width="100%",frame="topbot",options="header"]
|=============================================
|Entity type |Entity sub-type |Defining Module |Main uses |Examples

|Content item |Content type |Node module
  |Content intended to be the main page area for pages on the site
  |In the farmers market site example, you might have content types for
   basic pages, vendor pages, and recipe pages.

|Comment |Comment type |Comment module
  |Commentary added to content entities (typically to Content item entities)
  |On a blog site, blog posts might have comments. They are not needed in the
   farmers market site example.

|User profile |(none) |User module
  |Data related to a person with a user account (login access) on the site
  |Every site has at least basic user profiles with user names and email
   addresses; social networking sites may have more complex user profiles with
   more information.

|Custom block |Block type |Custom Block module
  |Text and images in smaller chunks, often displayed in the site header,
   footer, or sidebar
  |In the farmers market site example, you might put the hours and location in
   a sidebar block.

|Taxonomy term |Vocabulary |Taxonomy module
  |Used to classify other types of content
  |In the farmers market site example, you might classify Recipe content with an
   Ingredients taxonomy vocabulary, with taxonomy terms like Carrots and
   Tomatoes. In a blogging site, blog posts might be classified using a Tags
   vocabulary, and perhaps also a Categories vocabulary.

|File |(none) |File module
  |An image or attachment file that is tracked and managed by the site, often
   attached to other types of content
  |In the farmers market site example, both Recipe and Vendor pages might have
   image attachments, which would (behind the scenes) be managed as File
   entities by the site

|Contact form |Form type |Contact module
  |A form that lets site visitors contact site owners
  |A contact form is needed in the farmers market site example

|=============================================

==== What is a field?

Within entity items, the data is stored in individual _fields_, each of which
holds one type of data, such as formatted or plain text, images or other files,
or dates. Field types can be defined by the core software or by modules.

Fields can be added by an administrator on entity sub-types, so that all
entity items of a given entity sub-type have the same collection of fields
available. For example, the Vendor content type in the farmers market example
might have fields for the vendor name, a logo image, website URL, and
description, whereas the _Basic page_ content type might only have fields for
the title and page body. When you create or edit entity items, you are
specifying the values for the fields on the entity item.

==== Ähnliche Themen

* <<planning-structure>>
* <<content-create>>
* <<structure-content-type>>
* <<structure-taxonomy>>
* <<user-concept>>
* <<block-concept>>

// ==== Additional resources


*Attributions*

Written and edited by https://www.drupal.org/u/jhodgdon[Jennifer Hodgdon]
and https://www.drupal.org/u/gdunham[Grant Dunham].
