Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
<?php
/*
Plugin Name: CTA over hero image on inner pages
Plugin URI: https://www.damiencarbery.com
Description: Add a CTA on the hero image on inner pages (i.e. not on home page).
Author: Damien Carbery
Version: 0.1
*/
//<a class="button primary" href="#newsletter">Join Us Today</a>
add_action( 'essence_entry_header', 'dcwd_cta_on_inner_pages', 11 );
function dcwd_cta_on_inner_pages() {
if ( is_front_page() ) {
return;
}
echo '<a class="button primary" href="#">CTA Text</a>';
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.