In PrestaShop, managing hooks (also called positions or transplanting modules) from the back-office is straightforward. Here’s how you can hook, unhook, and transplant modules step by step.
🔹 1. Go to Positions (Hooks Page)
- Login to Admin Panel
- Navigate:
Design → Positions
(In older versions: Modules → Positions)
🔹 2. Transplant (Hook) a Module
This means attaching a module to a hook.
Steps:
- Click “Transplant a module” (top-right button)
- Fill details:
- Module → Select your module
- Hook → Choose where to display (e.g.,
displayHeader,displayFooter) - Exceptions → (Optional) hide on specific pages
- Click Save
👉 Example:
- Hook module to
displayHome→ shows on homepage - Hook to
displayFooter→ shows in footer
🔹 3. Unhook (Remove Module from Hook)
Method 1:
- In Positions page, find the hook
- Locate your module
- Click Trash/Delete icon
Method 2:
- Click Edit on module inside hook → remove or change position
🔹 4. Reorder Modules (Change Position)
- Drag & drop modules within a hook
- Or use Up/Down arrows
- Click Save positions
🔹 5. Use “Live Edit” (Optional Visual Way)
- Click “Run Live Edit”
- You can visually drag modules on front-end
- Save changes
⚠️ Note: Live edit may not work well on newer versions/themes
🔹 6. Important Hooks Examples
displayHeader→ CSS/JS loadingdisplayFooter→ footer contentdisplayHome→ homepagedisplayLeftColumn/displayRightColumndisplayProductExtraContent→ product page tabs
🔹 7. Reset Module (Quick Fix)
If hook not working:
- Go to Modules → Module Manager
- Find module → Click Reset
- Then re-hook again
🔹 8. Developer Tip (Important)
Some modules only work on specific hooks because:
- They are coded with specific hook functions like:
public function hookDisplayHeader() {}
If hook not exists in module → it won’t show
