Skip to main content

Posts

Showing posts from August, 2017

[Drupal 8]Build a simple hello_world Module

Drupal is one of the world's most widely used Content Management System. It is mainly used to create your own website and publish it using an online webhost. Drupal 8, its latest release, takes the lead over Drupal 7 since it brought along with it a lot of changes. Drupal 8 is also very fast and flexible.



Below are few steps you need to follow to create a module in drupal. A module is basically a simple page where you can add your own features by using Controllers, which we will later on in this article.
Click here to check out my blog post on how to install Drupal using composer. Structure of files i) An info.yml file - Module
ii) A routing.yml file - Routing File
iii) A Controller















Building the module

A module needs to have the .info.yml extension. This file will contain important information such as:
(i) name of the module
(ii) a description of what the module can do
(iii) the type, which can be module, profile or theme
(iv) package, which should be set to Custom if you are design…