Quick presentation of a hook
Before diving deep into the details, let’s describe quickly what hooks are. Hooks are like events that can be triggered from anywhere in the code and are mainly defined by a name. They can be placed anywhere in the controllers’ code of PrestaShop and in the Smarty or Twig templating code of the themes.
Modules are a kind of plugin, just like WordPress extensions. They can be attached to as many hooks as you want. The attachment of a module to a hook is called a registration. When you define a hook. Each hook execution can contain parameters provided to registered modules as a payload of information to transmit the necessary information.
Even if many hooks are pre-delivered in PrestaShop Core, you can also create your own hooks and use them from your modules. As hooks are ObjectModel
child objects, let’s see how hook features are stored inside the database.