My First Craft CMS Module

In this course you will learn how to create a Craft CMS module. At the end of the course you’ll be comfortable with getting up and running and bootstrapping your way to solving your own problems with a module.

Start Course
Ryan Irelan

I am the creator of CraftQuest, a web developer, and former software team manager. I spend most of my time improving CraftQuest with code and courses. When I'm not in front of the computer, I spend my time with my family, and running on the roads and trails of Austin, TX.

My First Craft CMS Module is made up of the following videos:

1Getting Started with a ModuleWe cover what a module is and what we'll build in this course. 03:22
2A Basic Module Class FileWe code a very simple module class file. 05:13
3Module Class Autoloading and BootstrappingWe make sure our module code will run in the Craft application by updating the Composer autoloader files and adding it to the Craft bootstrap config. 04:13
4Using an Event to Customize the Craft Control PanelWe add some feature code to the module to add a nav item to the Craft control panel. 08:40
5Generating a Module Scaffolding with PluginFactory.ioWe generate a module scaffolding using and then use it for our simple module approach using the init() method. 07:53
6Restructuring the ModuleWe redo the module structure to use a src directory and make plans to add a service class. 05:10
7Adding a Service to a Craft Module, Part 1We start out with our service by adding a new service class file. 02:39
8Adding a Service to a Craft Module, Part 2We refactor the main module class file to make the init method simpler. 05:31
9Adding a Service to a Craft Module, Part 3We finish up our work by moving the nav item code into our new class method and refactoring some more. 11:28
10Learn from the Code that Came Before YouThere's always an opportunity to learn from the code of others. 06:09