How to create your first dupal Module

| Last Updated: | In: Core php, Drupal

Now i explain the simple and easy steps to create a first drupal module. Our first module will show simple text, format it, and display it as a block in the site’s layout. There are two important files that every module must have.

The first is .info file, and the second file is .module (dot-module) file, which is a PHP script file.


Important Files

1) Creating the .info and .module files
2) Creating a new module
3) Using basic hooks
4) Installing and configuring the module

A Place for the Module files

Go to the root directory –> sites –> all –> modules.
Create a folder name helloworld

.info File

.Module File

Installing a Module

Step #1: Enabling The Module


Displaying the Module’s Content


Tags: , , , , , , ,

About: Prem Tiwari

Prem Tiwari is founder of and Software developer from New Delhi (India). Follow Prem's development codes on facebook, and make sure you check out for the latest in web development related Tips with the complete code.

You may also like:

Follow us!

Get Free Access of 350+ Scripts

Don't worry you'll not be spammed!

Featured eBook

WordPress Security Guide

Learn how to implement security guideline in your WordPress site...


Pincode Finder

pincode-finder tool

Online Pincode Finder

Best tool to locate post Office address and pincodes of all india...