You can use the jetpack_photon_skip_for_url filter to exclude specific URLs from Photon. In your case, you can use that filter to exclude all URLs that are not from your site. You can check the documentation for a working example:
https://developer.jetpack.com/hooks/jetpack_photon_skip_for_url/
You can paste this snippet your theme’s functions.php file, or in a functionality plugin.
Text widgets don’t use Photon by default, but you can force them to use Photon with the code in this post:
https://jeremy.hu/jetpack-photon-text-widgets/
One Again Thank You Jeremy 😀
That won’t be possible without making changes to the Recent Posts Widget Extended plugin.
I would recommend that you contact the plugin authors and ask them to consider supporting Photon for the widget images displayed here.
You can open a new issue on their GitHub repository here.
To support Photon, they could use the jetpack_photon_url filter in their plugin. You can send them this example so they can find out more:
/**
* Add Photon support to any image.
* The jetpack_photon_url filter will allow Photon to serve the images if Jetpack's Photon module is on.
*
* The filter allows you to pass an image URL, and some optional parameters.
*
* @param string $image_url Any image URL can be used.
* @param array|string $args Optional options to manipulate images.
* @see https://developer.wordpress.com/docs/photon/api/
* @param string $scheme Optional scheme in which to return image.
* Accepts <code>http</code>, <code>https</code>, and <code>network_path</code> (no protocol).
*/
$image_url = 'http://mysite.com/img/logo.png';
$args = array(
'filter' => 'grayscale',
'resize' => '600,200',
);
echo apply_filters(
'jetpack_photon_url',
esc_url( $image_url ),
$args,
'https'
);
Thank for your recommendation.
Now i will open new issue, but i just see if they is not too friendly (many ticket not respond by them)
So what your recommmendation until they fix the problem?
What can i do to fix that, until the respond my ticket.
Thank you
I’m afraid I can’t really suggest a work-around, as it would involve editing the Recent Posts Widget Extended plugin files.
You’ll need to continue to use local images until the plugin is patched.
What Recent Post plugin (that have filtering by single or multiple categories or tags features) that you recommend and have support with photon.
I don’t know of any, but I’m not really familiar with Recent Post plugins I’m afraid. I’d recommend looking for options in the plugin directory and giving them a try.
Nice, I didn’t know about that plugin!