Talking Drupal #510 - Drupal Hooks: Drop 'em like their hot
Today we are talking about Drupal Hooks, why they got changed in core, and what to do now with guest Karoly Négyesi better known as Chx. We’ll also cover Media Folders as our module of the week.
For show notes visit:
https://www.talkingDrupal.com/510
Topics
- Deep Dive into Drupal Hooks
- The Evolution of Drupal Hooks
- Challenges and Solutions in Hook Conversion
- Community Involvement and Contributions
- The Future of Drupal Hook System
- Introduction to Procedural Hooks
- Understanding Theme Hooks
- Complexities of Preprocess Hooks
- Converting Hooks to Object-Oriented
- Impact on Contributed Modules
- Challenges in Core Conversion
- Future of Drupal Hooks
- Lightning Round and Conclusion
Resources
Guests
Károly Negyesi - ghost-of-drupal-past
Hosts
Nic Laflin - nLighteneddevelopment.com nicxvan
John Picozzi - epam.com johnpicozzi
Martin Anderson-Clutz - mandclu.com mandclu
MOTW
Correspondent
Martin Anderson-Clutz - mandclu.com mandclu
- Brief description:
- Have you ever wanted to have your Drupal site's media assets presented in a UI that evokes the hierarchy of a filesystem? There's a module for that.
- Module name/project name:
- Brief history
- How old: created in Apr 2025 by João Mauricio (jmauricio)
- Versions available: 1.0.3 which supports Drupal 10.3 and 11
- Maintainership
- Actively maintained
- Security coverage
- Test coverage
- Number of open issues: 9 open issues, 2 of which are bugs, although one was just fixed
- Usage stats:
- Module features and usage
- The module mimics a file structure by associating media entities with a taxonomy hierarchy
- It then provides an intuitive, drag-and-drop UI to move items between locations, drag in new items, or even search within a particular “folder”, including a recursive search
- When you drag in files, it uses “smart” logic to automatically assign files to Media bundles
- It provides a form display widget, a view display widget, a CKEditor plugin, and it’s compatible with other filesystem modules, like S3 File System
- This kind of interface is a requirement I’ve seen in RFPs by companies looking for a new CMS, so having this available as a drop-in solution
00:00 Introduction to Talking Drupal
00:39 Meet the Guest: Oli Nehi (chx)
01:46 Module of the Week: Media Folders
07:19 Deep Dive into Drupal Hooks
11:54 The Evolution of Drupal Hooks
15:46 Challenges and Solutions in Hook Conversion
26:09 Community Involvement and Contributions
34:31 The Future of Drupal Hook System
37:21 Introduction to Procedural Hooks
37:54 Understanding Theme Hooks
39:34 Complexities of Preprocess Hooks
41:49 Converting Hooks to Object-Oriented
45:08 Impact on Contributed Modules
51:03 Challenges in Core Conversion
59:02 Future of Drupal Hooks
01:04:33 Lightning Round and Conclusion