From d0a2b9a939d5e98c94e2e5ec656e87cd9e1383a0 Mon Sep 17 00:00:00 2001 From: mattgoud Date: Thu, 27 Aug 2026 15:25:28 +0200 Subject: [PATCH] Document actionNotFound hook Generated by prestashop:update:hooks-documentation. The hook was added to install-dev/data/xml/hook.xml in PrestaShop/PrestaShop@4ee3078 a few hours after PR #2158 regenerated the 9.2.x hook documentation, so it was missed. The files list was completed by hand: the generator only records a single origin file, while the hook is dispatched from three front controllers. Co-Authored-By: Claude Opus 5 (1M context) --- .../hooks/list-of-hooks/actionNotFound.md | 33 +++++++++++++++++++ 1 file changed, 33 insertions(+) create mode 100644 modules/concepts/hooks/list-of-hooks/actionNotFound.md diff --git a/modules/concepts/hooks/list-of-hooks/actionNotFound.md b/modules/concepts/hooks/list-of-hooks/actionNotFound.md new file mode 100644 index 0000000000..0d1ed7d50f --- /dev/null +++ b/modules/concepts/hooks/list-of-hooks/actionNotFound.md @@ -0,0 +1,33 @@ +--- +Title: actionNotFound +hidden: true +hookTitle: 'Action when a page is not found' +files: + - + url: 'https://github.com/PrestaShop/PrestaShop/blob/9.2.x/controllers/front/PageNotFoundController.php' + file: controllers/front/PageNotFoundController.php + - + url: 'https://github.com/PrestaShop/PrestaShop/blob/9.2.x/controllers/front/ProductController.php' + file: controllers/front/ProductController.php + - + url: 'https://github.com/PrestaShop/PrestaShop/blob/9.2.x/controllers/front/listing/CategoryController.php' + file: controllers/front/listing/CategoryController.php +locations: + - 'front office' +type: action +hookAliases: +array_return: false +check_exceptions: false +chain: false +origin: core +description: 'Allows modules to react when a page is not found - log it, redirect or perform other actions.' + +--- + +{{% hookDescriptor %}} + +## Call of the Hook in the origin file + +```php +Hook::exec('actionNotFound'); +```