Created
May 14, 2019 07:10
-
-
Save yousufansa/3be910769ced0c839ede785380ca413a to your computer and use it in GitHub Desktop.
Electro - Theme Option Site Logo Integration With Wordpress Custom Logo
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| if ( !function_exists( 'electro_child_set_custom_logo' ) ) { | |
| function electro_child_set_custom_logo() { | |
| if( function_exists( 'is_redux_activated' ) && is_redux_activated() ) { | |
| global $electro_options; | |
| if ( ! empty( $electro_options['site_header_logo']['id'] ) ) { | |
| $custom_logo_id = $electro_options['site_header_logo']['id']; | |
| set_theme_mod( 'custom_logo', $custom_logo_id ); | |
| } else { | |
| set_theme_mod( 'custom_logo', '' ); | |
| } | |
| } | |
| } | |
| } | |
| add_action( 'init', 'electro_child_set_custom_logo' ); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment