skip to Main Content

Custom Logo Icon

You can now upload a custom icon image via the Customizer instead of choosing from the theme's preset icon choices. But you can still use this snippet if you need to conditionally modify the icon html.

If you are using the Logo Icon option in the customizer but want a different output you can easily hook into the theme's filter to alter the output. Note, that this will only work if you have already selected an icon in the Customizer since the filter modifies the default output, if you have not selected an icon in the Customizer there is nothing to modify.

/**
 * Modify the logo icon HTML.
 *
 * @link https://total.wpexplorer.com/docs/snippets/custom-logo-icon-output/
 */
add_filter( 'wpex_header_logo_icon', function() {
	echo 'YOUR CUSTOM ICON HTML';
} );
All PHP snippets should be added via child theme's functions.php file or via the Code Snippets Plugin (or alternative plugin)
Back To Top