logo

Extra Block Types (EBT) - New Layout Builder experienceâť—

Extra Block Types (EBT) - styled, customizable block types: Slideshows, Tabs, Cards, Accordions and many others. Built-in settings for background, DOM Box, javascript plugins. Experience the future of layout building today.

Demo EBT modules Download EBT modules

âť—Extra Paragraph Types (EPT) - New Paragraphs experience

Extra Paragraph Types (EPT) - analogical paragraph based set of modules.

Demo EPT modules Download EPT modules

Scroll

Articles

16/10/2019, by mikhail
settings

Users - this is one of the main features of Drupal, we can create, delete users. Users on the site leave comments, reviews, materials. Drupal has user moderation systems. And this is only part of the functionality of Drupal, so we need to understand the admin panel of Drupal in order to manage all this.

Let's go to Account settings:

Drupal users

settings
10/10/2019, by mikhail
Views Relations

Relationships are a very important part of Drupal, so taxonomy terms and content, users and content, goods and the display of goods in commerce are combined. Thanks to this, we can display user fields when displaying material fields, and when displaying goods, we can display their price and article number.

Thanks to this, we can display user fields when displaying material fields, and when displaying goods, we can display their price and article number.

Views Relations
03/10/2019, by Ivan
Drupal Entity API

We have already figured out the Form API, the Fields API and we know how the data in Drupal gets into the database. Now let's look at the foundation of all Drupal sites, namely the Entity API.

You have probably noticed that the fields do not exist by themselves, but are “attached” to entities: nodes, blocks, taxonomy terms, views, etc. You can create bundle entities, for example, material types, block types, taxonomy dictionaries. But what if you need to create a new entity with your bundles? In this case, you will need the Entity API to create a new entity.

Drupal Entity API
03/10/2019, by Ivan
Entity fields

Retrieving field values in entities is fairly simple, but there are several ways to do this. Let's see how best to work with field values in custom code. You can always see the latest information on working with fields on the official website:

https://www.drupal.org/docs/8/api/entity-api/working-with-the-entity-api

In this article, we will look at examples of working with values. 

Entity fields
03/10/2019, by Ivan
Entity hooks

In past articles, we have already encountered hooks. In this article, we’ll take a closer look at hooks that help you work with entities.

In this article, you can read in general what hooks are and why they are needed:

http://drupalbook.org/drupal/92-what-hook-drupal-8

We will use hooks to add our custom code that will fire on certain events related to entities: add, delete, update.

You can see all the Drupal hooks on this page:

Entity hooks
03/10/2019, by Ivan
Event Dispatcher

The events system allows you to build more complex systems with the ability to change functionality using custom code for certain events. Many hooks from Drupal 7 have been replaced by events. This allowed to unify the work of many parts of Drupal and additional copy modules. The events system itself came from Symfony and consists of the following parts:

Event Subscribers - â€śSubscribers” to specific events are functions or methods that fire on certain events. In code, is a class that implements the class:

Event Dispatcher
03/10/2019, by disabled user

In this article we will consider Field Formatters, that allow us to edit the display of fields and display them on the page. 

In past articles, we created field type Link, in this article we will look at how these fields are displayed on the page and which class is responsible for it. Each field that you add through Drupal can be displayed on the page and edit its settings on the page Manage display.