ralph77
Forum Replies Created
-
You cracked the case! That CSS snippet helped and the photos are now showing directly on screen. So the conflicting CSS classes seemed to be the culprit. Thank you very much!!!
Hi!
Thank you very much for the swift reply. I took a look into the decoding=’async’ tag and found the following information:
Media improvements
WordPress 6.1 will automatically add
decoding="async"to image attributes. In simple terms, this function tells your visitor’s browser that it’s okay to load images a bit later in favor of other information and data. This results in the page loading the content much faster and also reduces page render time. This is a huge performance booster for any web page containing a lot of images. It’s also good to know that you can remove this function.Source: https://yoast.com/performance-improvements-wordpress-6-1/
—
So this is a general feature that seems to come with WP itself. Maybe something you might want to consider?
Thanks so this post (https://core.trac.ww.wp.xz.cn/ticket/56969#comment:6) I was able to turn this feature off. Now the img tag is clean, but the strange loading behavior is still there.
I also checked the <img> tag and the loading behavior is set to “eager” for all pictures, so no lazy loading involved. This is the content of a single <img> tag for example:
img alt=”The Great Orion Nebula (M42)” src=”https://farm66.staticflickr.com/65535/51048890256_2cb793dcdf_s.jpg” class=’square’ loading=’eager’ width=’75’ height=’75’
The strange thing is, that the behavior itself absolutely looks like lazy loading.
Long story short: turning on/off the “async” feature does not make a difference and the img tag looks clean to me.
Maybe you can take another look?
Thanks and cheers!
Forum: Fixing WordPress
In reply to: WP 6.1 can decoding=async be turned off?Thanks for your answer. I am talking about this here:
Media improvements
WordPress 6.1 will automatically add
decoding="async"to image attributes. In simple terms, this function tells your visitor’s browser that it’s okay to load images a bit later in favor of other information and data. This results in the page loading the content much faster and also reduces page render time. This is a huge performance booster for any web page containing a lot of images. It’s also good to know that you can remove this function.Source: https://yoast.com/performance-improvements-wordpress-6-1/
—
So this is a general feature that seems to come with WP itself. I was curious if I could turn this off somehow using the WP backend.
Another solutions seems to be editing the wp-includes/media.php file. See this source: https://developer.ww.wp.xz.cn/reference/functions/wp_img_tag_add_decoding_attr/
Is this something that is OK to do? Or should this better be left alone?
For what it’s worth, here is the missing information:
WP version: 6.1.1
Theme: Meteorite
Plug-in: Photonic (Image Gallery being pulled from flickr)Thanks.