This documentation provides a collection of useful code snippets for developers working with the ClickWhale WordPress plugin.
Use this hook if you want to execute an action after a ClickWhale link has been clicked.
add_action('clickwhale/link_clicked', function( $link, $link_id, $user_id = 0 ) {
// Do something
});
The hook provides information about the clicked link, the link ID and the user ID (if logged in).
Use this hook if you want to execute an action at the top of a ClickWhale link page.
add_action('clickwhale/link_page_head', function( $link_page, $link_page_id, $user_id = 0 ) {
// Do something
});
The hook provides information about the viewed link page, the link page ID and the user ID (if logged in).
More information about the plugin functionality can be found in the officia plugin documentation.