Created
June 23, 2013 16:24
-
-
Save StewartChamberlain/5845578 to your computer and use it in GitHub Desktop.
Purchase Overlay with conditionals
This file contains hidden or 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
| function sc_bottom_overlay() { | |
| if ( in_category ( 'genesis themes' ) ) { // Only display if in category | |
| $button_text = 'Purchase'; // Button Text | |
| $link_uri = 'http://YOUR_LINK_HERE'; // Url for button Link | |
| $overlay = '<div class="overlay"><span style="opacity:1;"><a class="overlay-button" href="'. $link_uri .'">'. $button_text .'</a></span></div>'; | |
| echo $overlay; | |
| } | |
| } | |
| add_action( 'genesis_after_footer', 'sc_bottom_overlay' ); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment