Skip to content

Instantly share code, notes, and snippets.

@yousufansa
Created December 20, 2018 13:02
Show Gist options
  • Select an option

  • Save yousufansa/c0645aa5382443bbeb69b46ed1c018da to your computer and use it in GitHub Desktop.

Select an option

Save yousufansa/c0645aa5382443bbeb69b46ed1c018da to your computer and use it in GitHub Desktop.
Jobhunt - Site Header Logo Custom URL ( Not For Custom Image Logo )
if ( ! function_exists( 'jobhunt_site_title_or_logo' ) ) {
function jobhunt_site_title_or_logo() {
$logo_url = '#your_custom_link';
if ( function_exists( 'the_custom_logo' ) && has_custom_logo() ) {
the_custom_logo();
} elseif ( function_exists( 'jetpack_has_site_logo' ) && jetpack_has_site_logo() ) {
jetpack_the_site_logo();
} elseif ( apply_filters( 'jobhunt_site_logo_svg', false ) ) {
echo '<a href="' . esc_url( $logo_url ) . '" class="custom-logo-link" rel="home">';
jobhunt_get_svg_logo();
echo '</a>';
} else {
echo '<a href="' . esc_url( $logo_url ) . '" class="custom-logo-link" rel="home">';
?>
<h1 class="site-title"><?php bloginfo( 'name' ); ?></h1>
<?php if ( '' != get_bloginfo( 'description' ) ) : ?>
<p class="site-description"><?php bloginfo( 'description' ); ?></p>
<?php endif;
echo '</a>';
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment