问题
I was wondering if it is possible to stop WordPress from creating multiple copies of imagens, but still keeping, let's say, "medium" size.
I already edited my functions.php
and the media options, leaving it all to "0", and it's fine. But, when I add an image do my post, the code reads as follow:
<img src="http://example.com/wp-content/uploads/2019/08/image.jpg" alt="" width="2008" height="1004" class="aligncenter size-full wp-image-XXXX" /></a>
I am using Jetpack and, for design reasons, I need the code to add the size to the image and change the "size-xxxx" class. For example:
<img src="http://example.com/wp-content/uploads/2019/08/image-1280x600.jpg" alt="" width="1280" class="aligncenter size-large wp-image-XXXX" /></a>
I can do this all manually, yes. But is there a way that I don't need to type this things everytime? Thank you!
来源:https://stackoverflow.com/questions/57659056/how-to-stop-wordpress-creating-multiple-copies-of-images-but-keeping-the-size-in