Vogue Hooks

To make Vogue even more flexible and easier for developers to be able to customize the theme to suit their own or their clients needs, we’ve now added hooks all over to be able to insert your own code wherever you maybe need to.

To get an understanding of how to use hooks please refer to the WordPress Plugin API Codex on WordPress.org.

If you’re looking for an easy way to find the hooks in a WordPress theme then we recommend you have a look at the Simply Show Hooks plugin.

 

List of WordPress hooks added to Vogue:

Header Hooks:

<?php do_action ( 'vogue_before_topbar' ); ?>

This hook sits before the top bar of the header.

vogue-hook-before-topbar

 

<?php do_action ( 'vogue_topbar_left_left' ); ?>

This hook sits on the left side of the left div in the header top bar.

vogue-hook-left-left

 

<?php do_action ( 'vogue_topbar_left_right' ); ?>

This hook sits on the right side of the left div in the header top bar.

vogue-hook-left-right

 

<?php do_action ( 'vogue_topbar_right_left' ); ?>

This hook sits on the left side of the right div in the header top bar.

vogue-hook-right-left

 

<?php do_action ( 'vogue_topbar_right_right' ); ?>

This hook sits on the right side of the right div in the header top bar.

vogue-hook-right-right

 

<?php do_action ( 'vogue_footer_bottombar_left' ); ?>

This hook sits on the left side of the footer bottom bar.

hook_footer_bottombar_left

 

<?php do_action ( 'vogue_footer_bottombar_right' ); ?>

This hook sits on the right side of the footer bottom bar.

hook_footer_bottombar_right

 

We will be adding more hooks.

Let us know if you’re needing hooks and where to add them.

 

Example of adding in your own hook:

You would add this code/function into your child themes functions.php file to insert the text/code/custom functionlaity.

/**
* Custom function adding code to the Vogue footer right hook
*/
function add_my_own_hook() {
    echo '<span style="background-color: red; font-size: 13px; color: #FFF; padding: 2px 8px;">HOOK HERE</span>';
}
add_filter( 'vogue_footer_bottombar_right', 'add_my_own_hook' );

 

Read more here: https://codex.wordpress.org/Plugin_API