Documentation

Hook Codex

Although WordPress already comes with a load of hooks, Headway adds to that and allows you have even more flexibility. Below are all of Headway’s hooks (actions and filters).

Layout Hooks

headway_before_everything (action)

headway_before_everything is ran right after the <body> tag is opened.

headway_page_start (action)

After the header, navigation, etc. Before the container <div>.

headway_after_everything (action)

Ran right before the <body> tag is closed.

Header, navigation, and all that jazz.

headway_before_header_link (action)

Before the header link. The header link is where your site name, banner, or logo will be.

headway_after_header_link (action)

After the header link. The header link is where your site name, banner, or logo will be.

headway_after_tagline (action)

Will be displayed after the tagline (or slogan) in the header.

headway_after_navigation (action)

Will be ran after the navigation container <div>.

headway_after_breadcrumbs (action)

Will be ran after the breadcrumbs container <div>.

headway_navigation_beginning (filter)

Will be ran inside the navigation <div> at the beginning. There is no default value.

headway_navigation_end (filter)

Will be ran inside the navigation <div> at the end. There is no default value.

Leafs

headway_leaf_top (action)

Ran at the top of the leaf HTML. Before the title and content.

headway_leaf_top_LEAF-ID (action)

Exactly the same as headway_leaf_top, but you can target a specific leaf.

headway_leaf_content_top (action)

Ran after the leaf title, but before the content. Placed inside the leaf-content <div>.

headway_leaf_content_top_LEAF-ID (action)

Exactly the same as eadway_leaf_content_top, but you can target a specific leaf. Placed inside the leaf-content <div>.

headway_leaf_content_bottom (action)

Ran after the content of the leaf. In other words, the complete bottom of the leaf. Placed inside the leaf-content <div>.

headway_leaf_content_bottom_LEAF-ID (action)

Exactly the same as eadway_leaf_content_bottom, but you can target a specific leaf. Placed inside the leaf-content <div>.

headway_leaf_bottom (action)

Ran at the bottom of the leaf HTML. After the title and content.

headway_leaf_bottom_LEAF-ID (action)

Exactly the same as headway_leaf_bottom, but you can target a specific leaf.

Posts

headway_above_post (action)

Above each post.

Accepted variables:

  1. $count – ID of post in loop. This is not the post ID. The top post would be 1, the second would be 2, and so on.
  2. $single (boolean) – Simply true or false if the post is single or not.

headway_above_post_single (action)

Above each post, but targeted for single posts.

headway_above_title (action)

Above each post title.

Accepted variables:

  1. $count – ID of post in loop. This is not the post ID. The top post would be 1, the second would be 2, and so on.
  2. $single (boolean) – Simply true or false if the post is single or not.

headway_below_post_title and headway_below_page_title (action)

Below each post title.

Accepted variables:

  1. $count – ID of post in loop. This is not the post ID. The top post would be 1, the second would be 2, and so on.
  2. $single (boolean) – Simply true or false if the post is single or not.

headway_below_content (action)

Below content of each post.

Accepted variables:

  1. $count – ID of post in loop. This is not the post ID. The top post would be 1, the second would be 2, and so on.
  2. $single (boolean) – Simply true or false if the post is single or not.

headway_below_post (action)

Completely below each post.

Accepted variables:

  1. $count – ID of post in loop. This is not the post ID. The top post would be 1, the second would be 2, and so on.
  2. $single (boolean) – Simply true or false if the post is single or not.

headway_below_post_single (action)

Below content of the post on a single template.

headway_below_comments (action)

Below the comments and comment form on a single post.

Pages

headway_above_page (action)

Above the page.

headway_above_page_title (action)

Above the page title.

headway_below_page (action)

Below the page.

Footer

headway_footer_opening (action)

Fires right after <div id=”footer”> is opened.

headway_before_copyright (action)

Displays before the copyright HTML.

headway_footer_close (action)

Fires right before <div id=”footer”> is closed.

headway_link (filter)

Contains the attribution back to the Headway website. If you are under a personal license you cannot use this hook to remove or hide the footer attribution in anyway (psh, that’s what developer licenses are for! After all, you CAN upgrade).

Default Value:

<p>Powered By <a href="http://www.headwaythemes.com" title="Headway Premium WordPress Theme">Headway</a></p>

headway_copyright (filter)

The copyright in the footer.

Default Value:

<p>Copyright &copy; '.the_date('Y', false, false, false).' '.get_bloginfo('name').'</p>

headway_go_to_top (filter)

The link in the footer linking to the top of the page.

Default Value:

<a href="#top">Go To Top</a>