Creating a basic content type

In this recipe, we will learn how to create a very simple content type called Menu item, which could be used in conjunction with Views to create a menu for a restaurant. To create the content type we will first set up the default fields; following this we will add a new field named Price.

Our Menu item content type will consist of the following fields:

  • Title (Node module element)
  • Body (Long text and summary)
  • Price (Decimal)

How to do it...

In the following steps we will be creating a new content type called Menu item, then adding and configuring a decimal field called price:

  1. Select Structure from the admin menu, then select Content types.
  2. Select +Add content type.
  3. In the Name field enter Menu item.
  4. In the Description field ...

Get Drupal 7 Cookbook now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.