• Resolved casbboy

    (@casbboy)


    I have a posts_grid shortcode that generates images based on the attributes set within the shortcode.

    The PHP for the image goes like:

    $attachment_url = wp_get_attachment_image_src( get_post_thumbnail_id($post_id), 'full' );
    $url            = $attachment_url['0'];
    $image          = aq_resize($url, $thumb_width, $thumb_height, true);

    Is there any way to get Ewww Optimizer to step in here and create a better optimized image size based on attributes?

    Cheers!
    Ryan

Viewing 1 replies (of 1 total)
  • Plugin Author nosilver4u

    (@nosilver4u)

    if you’re using the Aqua Resizer from here: https://github.com/syamilmj/Aqua-Resizer
    Then images are already being optimized, since it uses WP_Image_Editor to do the heavy lifting.

    You can check to be sure on the Bulk Optimize page and click Show Optimized Images. Or you can search the ewwwio_images table in your database for specific images.

Viewing 1 replies (of 1 total)
  • The topic ‘Have it Optimize Images Created on the Fly within Shortcode’ is closed to new replies.