Skip to content

Instantly share code, notes, and snippets.

@reasonstousegenesis
Created November 19, 2015 03:32
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 reasonstousegenesis/3764eb2441133c0327d4 to your computer and use it in GitHub Desktop.
Save reasonstousegenesis/3764eb2441133c0327d4 to your computer and use it in GitHub Desktop.
Add a placeholder description if none is set
<?php
// Paste the code BELOW this line into your child theme functions.
/**
* Add a placeholder description if none is set
*
* @author Reasons to Use Genesis
* @link http://reasonstousegenesis.com/site-description/
*/
add_action( 'genesis_site_description', 'rtug_placeholder_description' );
function rtug_placeholder_description() {
if ( ! esc_html( get_bloginfo( 'description' ) ) )
echo '<p class="site-description">Just another WordPress site</p>';
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment