• Hello amazing plugin!!.
    But I have a problem with this Offload Media Lite, it is very useful to load the images in aws. And with domain mapping the images are loaded from the local source.
    Please help!

Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author matthias.wagner

    (@matthiaswagner)

    hy,
    there are two options for that:

    *) you can comment out line 615 of “multidomainmapping.php” like that
    //add_filter( 'wp_get_attachment_image_src', array($this, 'replace_src_domain'), 10 );
    but that would get lost with each plugin update.

    *) you can unhook that filter which is added in this line. this needs some understanding of wordpress functions and php. adding this line to your functions.php or custom plugin should work

    add_action( 'plugins_loaded', 'customprefix_remove_mdm_plugin_filter' );
    function customprefix_remove_mdm_plugin_filter() {
        remove_filter( 'wp_get_attachment_image_src', 'FALKE_MultipleDomainMapping::replace_src_domain', 10 );
    }

    this code is untested. if it does not work out of the box, please stick to this thread to try different methods of unhooking: https://wordpress.stackexchange.com/questions/334421/how-to-remove-filter-added-by-another-plugin-in-a-class

    matt

    Thread Starter matiastapiac

    (@matiastapiac)

    Thanks Mat!
    But It doesn’t work, it keeps showing the content images locally. I even commented all the filters.

    //add_filter( 'script_loader_src', array($this, 'replace_domain'), 10 );
    				//add_filter( 'style_loader_src', array($this, 'replace_domain'), 10 );
    				//add_filter( 'stylesheet_directory_uri', array($this, 'replace_domain'), 10 );
    				//add_filter( 'template_directory_uri', array($this, 'replace_domain'), 10 );
    				//add_filter( 'the_content', array($this, 'replace_domain'), 10 );
    				//add_filter( 'get_header_image_tag', array($this, 'replace_domain'), 10 );
    				//add_filter( 'wp_get_attachment_image_src', array($this, 'replace_src_domain'), 10 );

    Any ideas? thanks for your time!

    • This reply was modified 3 years, 5 months ago by matiastapiac.
    Plugin Author matthias.wagner

    (@matthiaswagner)

    hy!
    hmm…

    since the content is delivered in original with these filters commented out, i don’t know what to do more from mapping-side. can you ask the media-plugin-authors for help? i’d guess that maybe they do not process the whole page because they do not recognize the url or something like that ?!?

    since this is nothing we use for our own purpose we can not dive deeper into troubleshooting here – i hope you understand that (cause the plugin is not developed commercially). but we will add the incompatibility to our backlog so we are aware of it and maybe get back to it anytime in the future.

    if you find out some thing please post it here, so other users can benefit from that as well!

    thanks and good luck
    matt

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘problem with Offload Media Lite’ is closed to new replies.