Support » Plugin: Media Library Assistant » Images from external sources

  • Resolved schumiholic

    (@schumiholic)


    Hi! I noticed that in Assistant, I can see more images than in Media. There are also included images which were not uploaded in WordPress Media, but are used from different external sources, like Flickr, for example, or from my server from another location. They are attached to posts though and I am thinking this is the reason I can see them there. But is there a way to disable seeing these images?
    Thanks!

Viewing 7 replies - 1 through 7 (of 7 total)
  • Plugin Author David Lingren

    (@dglingren)

    Thank you for this remarkable report, and for your question.

    Media Library Assistant, as the name implies, is designed to help manage and use items in the site’s Media Library. The Media/Assistant uses the WordPress WP_Query class for its database queries and I am not aware of any way this can find items not actually in the local Media Library. Perhaps you are running some other plugin that makes these “external” items visible, but that would surprise me.

    You wrote “They are attached to posts“. Again, as far as I know it is not possible to “attach” an item that is not stored in the local Media Library.

    I am at a loss to suggest an answer to your question, but I can investigate further if you can give me more details of your experience. I will leave this topic unresolved for now; any additional details you can provide would be helpful. Thanks for your interest in the plugin.

    This is what I am talking about: https://postimg.cc/gallery/RMJNBKJ

    MLA shows 53 images in May, while Media Library only 21. Those 32 images are not located in wp-content/uploads, they are even on another folder on my server which is not under WP installation, or on an external source. They are all featured images which I uploaded with the FIFU plugin (Featured Image from URL).

    I deactivated all plugins except yours and activated 2020 theme, it shows the same. Hope this helps with the investigation.

    Plugin Author David Lingren

    (@dglingren)

    Thanks for your update with the additional information and screen shots; very helpful. As I suspected, another plugin is involved:

    Featured Image from URL (FIFU)
    By Marcel Jacques Machado

    I installed the plugin on my system and ran a few tests. The FIFU plugin adds items to the WordPress Media Library (adding rows to the wp_posts database table), but does not actually upload the attached file. FIFU installs several actions and filters that make these items behave as Featured Images.

    FIFU has a settings option, “Media Library – Enable that to show the external images in your media library”, that adds the items to your Media/Library screen. By default this option is off; I suspect that’s true on your site. In this case FIFU adds a condition to the WP_Query parameters that suppresses its items from the submenu table. FIFU does not recognize MLA and does not modify MLA’s query, so the items show up on the Media/Assistant submenu table.

    If you turn the option on you should see the items show up. If you disable the plugin the items will appear with an icon in place of the thumbnail image. Is that working on your system?

    I will investigate the work required to detect FIFU and honor its “Media Library” option setting, either within the MLA core or perhaps as an example plugin. I will post an update here when I have progress to report.

    Yes, that option is indeed off and it doesn’t help to activate it, because I don’t want to see those images in neither Media, nor MLA. I only want to see the images in my Media and organise them into Att categories. I deactivated FIFU and what happens is that I no longer see the thumbnails, but the items still show up. In the File URL column, it looks like this: https://www.rolug.ro/wp-content/uploads/;https://www.rolug.ro/competitions/2020-zbor/img1_9017.jpg. Strange behaviour I might say.

    Thank you for looking into this and looking forward for an update 🙂 If you need any help from me, please let me know.

    Plugin Author David Lingren

    (@dglingren)

    Thanks for confirming the deactivated behavior. Yes, the File URL values look rather odd, but that’s some combination of WordPress and FIFU trying to combine the local uploads directory with the external source. There’s code in the FIFU plugin that straightens it out as needed.

    I have uploaded a new MLA Development Version dated 20200528 that includes support for FIFU and its Media Library option setting plugin. You can find step-by-step instructions for using the Development Version in this earlier topic:

    PHP Warning on media upload with Polylang

    Once the Development Version is installed MLA will detect and honor the FIFU setting controlling the visibility of its external items for the Media/Assistant admin submenu table and for the [mla_gallery] shortcode. You can turn visibility on with the FIFU option if you need it for any reason in the future.

    It would be great if you could install the Development Version and let me know if it works for you. Thanks for inspiring the MLA improvement.

    Yep, worked like a charm! I followed your steps and only the files uploaded in Media are visible.

    Thank you so much for your help!

    Plugin Author David Lingren

    (@dglingren)

    Thanks for the good news regarding the Development Version and its FIFU support.

    I am marking this topic resolved, but please update it if you have any other problems or further questions about MLA’s support for the FIFU plugin.

Viewing 7 replies - 1 through 7 (of 7 total)
  • You must be logged in to reply to this topic.