Switch XML Sitemap image URLs to CDN (nextgen images)
-
I use this code to change images link in my sitemap to cdn one:
function wpseo_cdn_filter( $uri ) {
return str_replace( 'https://example.com', 'https://cdn.example.com', $uri );
}
add_filter( 'wpseo_xml_sitemap_img_src', 'wpseo_cdn_filter' );
It is working for post’s images but not for nextgen gallery images (inside pages).
I still have example.com instead of cdn.example.com
Does this code work only for post’s images?
Any idea how to fix this?
Thanks
Viewing 5 replies - 1 through 5 (of 5 total)
Viewing 5 replies - 1 through 5 (of 5 total)
- The topic ‘Switch XML Sitemap image URLs to CDN (nextgen images)’ is closed to new replies.