WordPress.org

Ready to get started?Download WordPress

Forums

W3 Total Cache
Importing attachments needs to use proper attachment URLs (1 post)

  1. Artem Livshits
    Member
    Posted 1 year ago #

    Hi Frederick,

    Would it be possible to apply the following 1-line fix

    --- a/wordpress/wp-content/plugins/w3-total-cache/lib/W3/Plugin/CdnAdmin.php
    +++ b/wordpress/wp-content/plugins/w3-total-cache/lib/W3/Plugin/CdnAdmin.php
    @@ -559,6 +559,7 @@ class W3_Plugin_CdnAdmin extends W3_Plugin {
                                                      */
                                                     require_once ABSPATH . 'wp-admin/includes/image.php';
                                                     wp_update_attachment_metadata($id, wp_generate_attachment_metadata($id, $dst));
    +                                                $dst_url = wp_get_attachment_url($id);
    
                                                     $attachments[$src] = array(
                                                         $dst,

    so that importing attachments into Media Library works with plugins that use alternative storage for media files, such as WP2Cloud?

    W3 Total Cache version is 0.9.2.5.

    Thank you!

    -Artem

    http://wordpress.org/extend/plugins/w3-total-cache/

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic

Tags

No tags yet.