Hey Doug,
Thanks for the detailed info!
Unfortunately, we have to store absolute paths in the CSS/JS cache since there are cases where relying on the relative path won’t work. They are edge cases, but if we don’t support them, images won’t show on sites with unique configurations.
Additionally, it’s WordPress itself that’s giving us these absolute URLs when you select a photo, so this is something that affects other plugins as well.
I know that WPE is rewriting URLs in the HTML, and that we can’t expect them to rewrite URLs in our cache. However, we did recently implement a filter that might help with this.
I haven’t tested it, but this should rewrite the URLs in our cache to use WPE’s CDN. Go ahead and give this a shot, clear the BB cache and let me know if it works.
function fl_builder_rewrite_cdn_urls( $css ) {
return str_ireplace( 'sensiblemystic.com', '1u3p3qzf26gy1vo33fisw914-wpengine.netdna-ssl.com', $css );
}
add_filter( 'fl_builder_render_css', 'fl_builder_rewrite_cdn_urls' );
Thanks!
Justin