Theme Action Hooks

This is a developer level topic and isn’t required reading for normal usage of Polestar. If you’re interested in theme customization at a code level and want to find out about action hooks, see Using Action Hooks in WordPress Child Themes.

Polestar offers the following action hooks for you to use:

header.php

polestar_body_top

This hook is located immediately after the opening body tag.

polestar_header_before

This hook is located directly before the opening masthead tag.

polestar_menu_before

This hook is located directly before the main menu.

polestar_menu_after

This hook is located directly after the main menu.

polestar_content_before

This hook is located after the close of the masthead and before the opening of the site-content div.

polestar_content_top

This hook is located after the opening of the site-content div and after the opening of the polestar-container div.

footer.php

polestar_footer_before

This hook is located after the close of the content div, immediately before the start of the footer.

polestar_footer_top

This hook is located immediately after the footer opening before the opening of the polestar-container div.

polestar_footer_bottom

This hook is located below the bottom bar, immediately before the close of the footer tag.

polestar_footer_after

This hook is located directly after the wp_footer function and before the closing body tag.

Last updated: 09/08/2020