skyrant
Forum Replies Created
-
removed plugin, cleaned up directories, re-installed. Seems to work now.
Not resolved, still broken.
Server Time: 2019-10-01 16:44:17 UTC (2019-10-01 18:44:17 Europe/Berlin)
Browser Time: Tue, 01 Oct 2019 16:44:16 GMT (Tue Oct 01 2019 18:44:16 GMT+0200 (Central European Summer Time))Will not accept my 2FA
Forum: Fixing WordPress
In reply to: Inline styles for site identity logo have to go!the remove function is not even needed.
Forum: Fixing WordPress
In reply to: Inline styles for site identity logo have to go!The cropping is based on the custom-logo attributes. These options should be exposed to the users in the site identity page.
The blanks around the function braces are cosmetic and have no impact on the code.
- This reply was modified 6 years, 8 months ago by skyrant.
Forum: Fixing WordPress
In reply to: Inline styles for site identity logo have to go!The reason the width and height attributes are 200 and 74 respectively in your example is because those are the dimensions of your image. Your image is 200×74.
No, my image is 300×112. It get’s forcefully resized by WordPress when i change it through the theme customisation (site identity -> logo) and then what get’s included is the cropped image. It even has cropped in the name!|
I want it to set the width and height to the actual image size i use. No matter what size the image is. If i want to upload a 4000×4000 logo then let me do it. These restrictions are not helping at all.
PS: The code you provided worked. Would be nice to add this to the WordPress documentation. nowhere does it say you have to remove_theme_support() first.
add_action( 'after_setup_theme', 'yit_child_theme_setup', 20 ); if ( ! function_exists( 'yit_child_theme_setup' ) ) { /** * load child language files * * * @return void * @since 1.0.0 * @author Francesco Licandro */ function yit_child_theme_setup() { load_child_theme_textdomain( 'yit', get_stylesheet_directory() . '/languages' ); remove_theme_support('custom_logo'); $defaults = array( 'height' => 112, 'width' => 300, 'flex-height' => true, 'flex-width' => true, ); add_theme_support( 'custom-logo', $defaults ); } }
Forum: Fixing WordPress
In reply to: Inline styles for site identity logo have to go!<img width="200" height="74" src="https://static.digitalitem.trade/shop/wp-content/uploads/2018/03/cropped-Digital_Item_Logo_300px-5.png" class="custom-logo" alt="Digital Item Trade" itemprop="logo">
Whatever i upload as logo get’s cropped without my approval instead of using the original image.
The
<img />
tag gets an inline width and height attribute for no reason at all.There is a style for the logo. Why hard code it into the tag?