metaslider_resized_image_url

Description

This this filter to modify the slide image URL used by Meta Slider. For example, it could be used to change the full image URL to a relative image URL.

Parameters

$cropped_url

(string) (required) The URL to the cropped/resized image (e.g. http://[…]/image-150×150.jpg)

$orig_url

(string) (required) The URL to the full size image (e.g.  http://[…]/image.jpg)

Examples

Protocol Relative URLs

The example below will remove the “http:” portion of the image URL, making it into a “protocol relative URL”. This will allow the image to be loaded over the same protocol as the page itself (ideal for https pages).

Disable Cropping

The example below effectively disables cropping by returning the original, full size image URL for each slide.