Reply to comment
The Magic of Drupal #2 – It’s All About the Modules
ronnie.norwood — Sun, 09/18/2011 - 19:05
One thing I noticed right away when I became involved with Drupal was that I was seldom part of any discussion about it without somebody talking about one module or another. Modules are at the heart of Drupal. Think of a module as a self-contained unit of source code. Referring back to the puzzle illustration in post #1 of this series, each chunk of the puzzle, containing multiple pieces and already pre-assembled, represents a module.
In the Drupal structure, there is a set of modules called the core which comprises the fundamental functionality. The core in the latest version of Drupal 7 (7.8) contains 44 modules. All of the other modules outside of core are referred to as contributed and are numbered in the thousands. Custom modules, ones that have been written but not already contributed to the community, can also be included. You combine the modules you need to form the building blocks of your Drupal website.
Here are 3 key characteristics of Drupal modules:
Every module is made up of a set of files and each file has its own purpose and a standard name format. The naming convention for a module file is the module name plus a specific extension. Each module set is made up of a configuration file with an info extension, coupled with a file with a module extension containing the source code. Optionally, other files can be created, such as a file with an install extension to perform initial database actions.
Every module is designed to perform a specific function. If you are a Drupal administrator who wants to put a special dynamic dropdown menu across the top of your website, there is a module for that. Do you need to put eCommerce on your site ?? Use the Drupal Commerce module. Would you like to include social media ?? Try the Statuses module. Some modules, such as the Drupal Commerce module, not only satisfy the need for a particular feature but have grown their own following, so much so that they have unique websites dedicated to them.
All modules are not created equal. That means in quality and popularity. You will need to go through a weeding out process to find the gems you want to fulfill a certain purpose on your website because unfortunately, some modules are simply not as high quality as others in what they do, how easy they are to use, how reliable they are, and the accuracy of their documentation. Also, the fact is that some modules are simply more popular than others and so are included on more websites. The Administration Menu module mentioned above, Views, Pathauto, Date, and Webform are just a few examples.
I believe that grasping the importance of modules as well as understanding their categories and characteristics will put you well on your way to constructing great Drupal websites and maybe even writing some of your own modules. In the next post of the series, we will discuss the Drupal file structure and how the modules fit into it.
