Created
August 11, 2020 23:15
-
-
Save damiencarbery/ee276fb3f311a63c7891a99da0ec9db9 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?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