Where are the src and srcset sizes coming from?

Themes and plugins can use the add_image_size function to define image sizes. Whenever an image is uploaded, WordPress will generate a separate image file for every size that is defined. Now, when you insert an image in your post, WordPress will ask you which size you want to use by default. This will be the … Read more

Get URL from all images in a post

You probably can’t find any attached images because those images are not considered ‘attached’ or have been attached to another post before. With this script you can search directly in the_content() for all the attached images and then create another list with only the <img> tags cleaned from the rest of the text. $post_content = … Read more

Weird failing request

Can you help me identify what the problem is and how can I prevent this? Where is this request coming from? The shortcode is only processed on the frontend. As far as the block editor is concerned the URL specified is [picsum] which is an unprocessed shortcode. There is no simple fix to this, and … Read more

Skewed / slanted button within elementor [closed]

What you need is to select Elementor buttons and add a simple custom CSS. Basically what you need to do is to skew the button with the negative value, and then skew the inner text element with the positive value. a.elementor-button { color: #fff; background: #000; border: 2px solid #000; font-weight: 700; text-align: center; text-decoration: … Read more

Images under 1MB are not being compressed

The closest answer you will find to the exact question you asked is: that feature does not exist, WordPress does not have an image compression feature. That’s not how compression works, compression isn’t something WP does. Your understanding of how WordPress handles image uploads, and your expectations, are incorrect. WP does not store images in … Read more