Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Add line breaks to Genesis site description. Source: http://www.michaelcarwile.com/add-line-breaks-to-wordpress-site-description/
<?php
//* Replace default site description with description containing line breaks
remove_action('genesis_site_description', 'genesis_seo_site_description');
add_action('genesis_site_description', 'prefix_site_description_with_br');
function prefix_site_description_with_br() {
$blogdesc = get_bloginfo('description');
$blogdesc = preg_replace("/, */", "<br>", $blogdesc); ?>
<p class="site-description"><?php
echo $blogdesc; ?></p>
<?php
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment