First of all, you need to make sure that the system allows you to download svg files. To do this, add the following code to your function.php:
//allow svg files require get_template_directory() . '/inc/customizer.php'; function cc_mime_types($mimes) { $mimes['svg'] = 'image/svg+xml'; return $mimes; } add_filter('upload_mimes', 'cc_mime_types'); [php] Carefully check that the parameters have been added '<i>flex-width' => true</i>, '<i>flex-height' => true</i>, in the initialization function of your logo (try find them in function.php): [php] function custom_theme_setup () { add_theme_support( 'custom-logo', array( 'height' => 250, 'width' => 250, 'flex-width' => true, 'flex-height' => true, ) ); } //add on hook after_setup_theme add_action('after_setup_theme', 'custom_theme_setup');
! Upload a logo that no longer needs the crop function. It will not work with svg.
! Be careful that the container in which the logo is located may not have a clearly defined height. The logo will simply not be added to the site. To display the logo, add a minimum height in CSS:
.logo-container { min-height:250px; }