Support » Plugin: Custom Content Shortcode » srcset missing when using content shortcode

  • I am using the shortcode below to include some content into an event description (Events Calendar plugin) and my images are missing the srcset attributes I see when looking at the original post:

    [content type=topic name=my-topic]

    Any idea why this may be happening?

Viewing 2 replies - 1 through 2 (of 2 total)
  • For now, I have worked around this issue by adding the following filter:

    // Add response image filter to custom content shortcode content
    add_filter('doing_ccs_shortcode', 'wp_make_content_images_responsive', 20);

    I believe this should be fixed in the plugin. Note sure if it’s just a matter of filter priority on the_content.

    I changed my workaround as follows:

    remove_filter('the_content', 'wp_make_content_images_responsive');
    add_filter('the_content', 'wp_make_content_images_responsive', 13);

    I also found one my theme options was interfering with srcset/sizes, so I disabled that option.

Viewing 2 replies - 1 through 2 (of 2 total)
  • You must be logged in to reply to this topic.