Skip to content

Instantly share code, notes, and snippets.

@braginteractive
Created May 10, 2017 18:17
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save braginteractive/409eb274c438c11baddd06775ada8a91 to your computer and use it in GitHub Desktop.
Save braginteractive/409eb274c438c11baddd06775ada8a91 to your computer and use it in GitHub Desktop.
Code to display Hero Banner and Text
<?php
$hero_image = get_theme_mod( 'hero_image', '' );
$hero_text = get_theme_mod( 'hero_text', '' );
?>
<div class="sp-hero" style="background-image: url('<?php echo esc_url( $hero_image ); ?>')">
<h1><?php echo $hero_text; ?></h1>
</div>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment