Adds link (and option to change it) to the footer logo. #38
This commit is contained in:
parent
e399cc775e
commit
787659e72f
|
@ -44,13 +44,15 @@
|
||||||
$footerImage = get_theme_mod( 'tainacan_footer_color', 'dark' ) == 'light' ? esc_url( get_template_directory_uri() ) . '/assets/images/logo.svg' : esc_url( get_template_directory_uri() ) . '/assets/images/logo-footer.svg';
|
$footerImage = get_theme_mod( 'tainacan_footer_color', 'dark' ) == 'light' ? esc_url( get_template_directory_uri() ) . '/assets/images/logo.svg' : esc_url( get_template_directory_uri() ) . '/assets/images/logo-footer.svg';
|
||||||
}
|
}
|
||||||
?>
|
?>
|
||||||
<img src="<?php echo $footerImage; ?>" class="tainacan-footer-info--logo" >
|
<a href="<?php echo get_theme_mod('tainacan_footer_logo_link', 'https://tainacan.org') ?>">
|
||||||
|
<img src="<?php echo $footerImage; ?>" class="tainacan-footer-info--logo" >
|
||||||
|
</a>
|
||||||
</div>
|
</div>
|
||||||
<div class="col-12 tainacan-powered">
|
<div class="col-12 tainacan-powered">
|
||||||
<span>
|
<span>
|
||||||
<?php if ( true == get_theme_mod( 'tainacan_display_powered', false ) ) {
|
<?php if ( true == get_theme_mod( 'tainacan_display_powered', false ) ) {
|
||||||
/* translators: 1: WordPress; 2: Tainacan*/
|
/* translators: 1: WordPress; 2: Tainacan*/
|
||||||
printf( __( 'Proudly powered by %1$s and %2$s.', 'tainacan-interface' ), '<a href="https://wordpress.org/">WordPress</a>', '<a href="http://tainacan.org/">Tainacan</a>' ); } ?>
|
printf( __( 'Proudly powered by %1$s and %2$s.', 'tainacan-interface' ), '<a href="https://wordpress.org/">WordPress</a>', '<a href="https://tainacan.org/">Tainacan</a>' ); } ?>
|
||||||
</span>
|
</span>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -77,7 +77,6 @@ function tainacan_customize_register( $wp_customize ) {
|
||||||
'capability' => 'manage_options',
|
'capability' => 'manage_options',
|
||||||
'sanitize_callback' => 'tainacan_sanitize_upload',
|
'sanitize_callback' => 'tainacan_sanitize_upload',
|
||||||
) );
|
) );
|
||||||
|
|
||||||
$wp_customize->add_control(
|
$wp_customize->add_control(
|
||||||
new WP_Customize_Image_Control($wp_customize, 'tainacan_footer_logo',
|
new WP_Customize_Image_Control($wp_customize, 'tainacan_footer_logo',
|
||||||
array(
|
array(
|
||||||
|
@ -88,6 +87,18 @@ function tainacan_customize_register( $wp_customize ) {
|
||||||
)
|
)
|
||||||
);
|
);
|
||||||
|
|
||||||
|
$wp_customize->add_setting( 'tainacan_footer_logo_link', array(
|
||||||
|
'type' => 'theme_mod',
|
||||||
|
'capability' => 'manage_options',
|
||||||
|
'default' => 'https://tainacan.org',
|
||||||
|
'sanitize_callback' => 'sanitize_text_field',
|
||||||
|
) );
|
||||||
|
$wp_customize->add_control( 'tainacan_footer_logo_link', array(
|
||||||
|
'type' => 'theme_mod',
|
||||||
|
'label' => __( 'Logo link', 'tainacan-interface' ),
|
||||||
|
'section' => 'tainacan_footer_info',
|
||||||
|
) );
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Checkbox to display or no the Proudly Powered by WordPress and Tainacan.
|
* Checkbox to display or no the Proudly Powered by WordPress and Tainacan.
|
||||||
*/
|
*/
|
||||||
|
|
Loading…
Reference in New Issue