From 60262f687626cfff9e4b020695e73941761412ac Mon Sep 17 00:00:00 2001 From: Dac Chartrand Date: Tue, 11 Jun 2019 10:25:22 -0400 Subject: [PATCH] Contact Link, Another Alternative (#187) Remove the Contact footer link altogether when neither the form nor a link has been added Fixes: pressbooks/ideas#180 --- footer.php | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/footer.php b/footer.php index 3a62436..1fd7dfd 100644 --- a/footer.php +++ b/footer.php @@ -23,9 +23,15 @@ if ( $pb_network_contact_form ) { if ( ! empty( $pb_network_contact_link ) ) { $contact_link = $pb_network_contact_link; } else { - $contact_link = 'mailto:' . get_option( 'admin_email' ); + $contact_link = ''; } } +/** + * Filter the "Contact" link. + * + * @since Pressbooks 5.6.0 + */ +$contact_link = apply_filters( 'pb_contact_link', $contact_link ); ?> @@ -87,8 +93,10 @@ if ( $pb_network_contact_form ) {