Knowledgebase

How to create Drupal content types

Drupal comes preconfigured with a few content types that you can use for publishing content (nodes). If you want to, you can create your own content types, and you can also edit any existing ones. To do this, log in to the admin panel of your Drupal, click on the Structure tab in the navigation bar, and on the page that opens click on Content types. To edit any content type just click on its edit button in the table that's displayed on the following page. To create a new one click on the Add content type button that's above the table. When you do this you'll see the general settings for the content type that you're about to create.

Type the name of the content type in the corresponding field, and optionally a short description in the text area labeled Description. This description will be shown only in the admin panel. Below the text area for the description there are several buttons on the left side. Each one displays various settings that are preconfigured to some default values (always the same when creating a new content type). You can use the Submission form settings to change the default label for the title field; you can select whether nodes from that content type should be previewed before submission, and you can include some explanatory guidelines. These settings are relevant only when creating/editing a node; they won't have any effect on the frontend. From the Publishing options you can choose whether nodes should be automatically published on the frontend after you create them; whether they should be put on the home page, and you can also enable the option which sticks the nodes to the top of the home page.

The Display settings button allows you to choose whether authoring information should be shown on the frontend. From the Comment settings you can select whether nodes from that content type will be open or closed for comments; you can select the number of comments per page, you can enable/disable comment titles, etc. Use the Menu settings to configure which menus will be available for putting links in them for the nodes from that content type.

After you're done with these settings click on the Save content type button to save the content type and exit the settings screen, or on the Save and add fields button to save the content type and configure its fields. In any case you can configure the fields at any time. The content type will be functional even if you don't change any of the field settings. It will be added with two default fields: for a title and a body of text.

For more details and screenshots you can also read our Drupal content types tutorial.

Was this answer helpful?

 Print this Article

Also Read