Stack Exchange Network

Stack Exchange network consists of 174 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Media Library is a WordPress panel that display all files you've uploaded. There you can add new files, attach files to posts and pages etc.

0
votes
1answer
15 views

how do prevent wordpress from creating permalinks for media files

Could one please explain how can I prevent WordPress 4.9 from creating permalinks/slugs for Media files without the need of installing another plugin? It's also important that the solution won't get ...
1
vote
0answers
17 views

Is it possible to share media files between multiple WordPress sites?

We've got around ten or so WP sites on different instances of WP (each with it's own database), most of them are on the same server but not all of them. We would like to achieve a situation where an ...
0
votes
1answer
21 views

Bulk upload images in upload folder does not show in media library

my website currently in staging site and I host it locally. Today, I upload some pictures from Live website to wp-content > upload folder but It does not show in Media library, however if I use ...
0
votes
1answer
9 views

Schedule image post on download

I have lots of schedule posts containing external images and I want to be able to auto download the images & linked to media library when the post status changes to publish. This is the code so ...
0
votes
0answers
11 views

How to fix custom add menu page preventing media library from loading

functions.php require get_parent_theme_file_path( '/inc/option-admin-page.php' ); option-admin-page.php function admin_page(){ add_menu_page('menu page','Option Panel','administrator','...
0
votes
0answers
12 views

Replace media hook

We have developed a custom image media plugin. But now i need to force all media buttons (wordpress wide) to open our plugin not the default wordpress media viewer. How do I do that?
0
votes
0answers
9 views

media selector on woocommerce costum field

I'm using this snippet to add a costum field in the product's general options panel in woocommerce add_action('woocommerce_product_options_general_product_data', 'woocommerce_product_custom_fields'); ...
0
votes
0answers
13 views

Media search input in admin section gets auto filled by Chrome

When you go to Wordpress Media folder, Chrome Auto fills the Search form field, with the username from when the admin/shop manager logs in. How can i fix this? The problem came out of no where. ...
0
votes
1answer
26 views

Image Upload Custom Form Field for Category and Custom Taxonomy

I am currently customizing a Wordpress Theme, and I want to add a new form field on Category for uploading an image. The image should be retrieved from the Media Library. I found out that there are ...
0
votes
1answer
23 views

Removing images deleted from uploads folder, from Media Library

How can I remove images that have been deleted from the upload folder, from the Media Library?
1
vote
2answers
63 views

WordPress Issue : The uploaded file could not be moved to wp-content/uploads/

I have created a local WordPress 4.9.8 setup with PHP 7 inside a Fedora running machine. When I try to upload media into the WordPress admin, it keeps saying that The uploaded file could not be ...
0
votes
0answers
36 views

Delete images for unused media image sizes, without regenerating other thumbnails

I have set 5 custom image sizes in my theme. On top of the 3 default image sizes, I have around 10 other unused image sizes from a plugin that I'm not using anymore. I want to delete the images for ...
1
vote
1answer
13 views

Convert (-) and (escape) signs to (_) when uploading files on wordpress media library automatically

For internal purpose, I'm looking for to convert (-) and (escape) sign to (_) automatically when we upload a file (photo,video,audio) on WordPress media library. Example: If i try to upload this 2 ...
2
votes
1answer
101 views

Download external images if post is publish

I have scheduled posts that contain external images. I want it to automatically download images & linked to the media library if the post status is publish. Now the problem is my code won't ...
0
votes
0answers
11 views

Only allow 1 Image to be uploaded at a time

I need to disable multiple uploads at a time. I am using wp.media.frames on the front end of the site, and cannot use upload_prefilter since it would need to check a post for total uploads - which is ...
0
votes
0answers
7 views

Force user to position and zoom image within a fixed frame when uploading to media library

I am looking to have an image editor similar to that provided by this Plugin https://wordpress.org/plugins/digiwidgets-image-editor/ but integrated into the core media library in Admin. For example ...
0
votes
0answers
27 views

How can I use an image from an external source without uploading it to the media library

I am looking for a way to tweak my xml parser code to insert a url from an external source into a new post, instead of first uploading it to the website's media library and than adding the attachment. ...
1
vote
1answer
53 views

Check if the image exists in WordPress media library

I have developed a plugin to insert posts using cron jobs. I am creating post thumbnails using this function: function Generate_Featured_Image( $image_url, $post_id ){ $upload_dir = ...
0
votes
1answer
27 views

WooCommerce CSV Image URL Creates Additional Images in Media Folder

I upload all images through the Media Library Drag and Drop Uploader with no problems. Every time I use a CSV file with several thousand products, I enter the image url for each product, which is ...
0
votes
0answers
11 views

Media libarary | wp-content/uploads missing file

I've been experiencing the problem that files are either completely missing from the directory uploads or are within a different directory within uploads. For example: /wp-content/uploads/2017/09/i-...
0
votes
1answer
11 views

How to bulk Edit Dates in Media Library?

I can't seem to find this option, but is there a way to bulk edit the dates of media items? I'm trying to go through my media and clean it up and I'd like to batch edit the dates of images (they'd be ...
0
votes
0answers
43 views

WP multisite to use one media library for all sub-site

I am working on a Multisite project. Overview: We are creating the content/posts on main site using Visual Composer page builder plugin and then cloning that post across all sub site using a cloner ...
0
votes
0answers
13 views

Add Media Dialog In WordPress Post Screen Too Confusing For My Users

How can I edit the contents of the Add Media box (shown above) in the WordPress post screen? All these options are unnecessary for my users, and I need to edit the short-codes as well, but it needs ...
0
votes
1answer
15 views

How to change the text of the “You are about to permanently delete these items…” alert message when deleting media from the media library?

This alert shows when you click Delete Permanently on a media (attachment) item. My Goal: I want to change the text of the alert if the current user has a certain custom meta value. Also, changing ...
0
votes
1answer
176 views

Some Images Disappeared from Media Library?

I am missing some of my images in my Media Library on my site. When I go and look in the Media Library it shows where the images used to be with a blank thumbnail and if I try to view those images it ...
0
votes
0answers
31 views

Wordpress media library don't load most of the photos in library

Whenever i try to load photos in the media library of my wordpress woocommerce site only the view at the top appear and the rest display "Failed to load resource: the server responded with a status of ...
0
votes
0answers
17 views

Change media author to post author

I have many users images that I uploaded. I need the author of these images to be changed to the author id as I have restricted each user to view only their own media, and of course the images for ...
-1
votes
1answer
22 views

Why is my upload / Select media library button empty?

The button seems to exist but the content of the button is empty. I have tried: Disabling all the plugins Downloading again wordpress and overwriting wp-includes and wp-admin with the original ...
0
votes
0answers
19 views

Pulling images from the media folder category to display inside a page

I'm looking to pull images from the media library by a certain category. The images are uploaded by the client themselves via the Media menu in the admin panel and they also select the category. The ...
2
votes
1answer
43 views

How can I make the Uploaded field editable for Media Library?

The 'uploaded' date field for Media Library entries is read only. Is there a way to make it editable from the Attachment Details window in upload.php? I've tried the following code as a plug-in. It ...
1
vote
3answers
36 views

HTTP Error when uploading files above 7mb unless using GD Image Editor

I noticed recently that when uploading files larger than 7mb to a Wordpress site that I developed, I get an HTTP Error. I've checked some of my PHP variables, and have verified that memory_limit is ...
0
votes
0answers
160 views

How to upload multiple images using WP rest API to media?

I'm using JWT Authentication for WP REST API plugin and WP REST API Controller plugin Take this rest api for example, it's an api for this post, and here's the media I understand everything about ...
0
votes
0answers
49 views

correct way to call images from Photon CDN

I am having a bit of difficulty finding the correct way to call images from the CDN that I use - Photon from Jetpack Prevouisly - called them direct from the upload source wp-content/themes/mytheme/...
0
votes
0answers
78 views

Frontend Media Upload throws TypeError mediaelementplayer

I am trying to add a media upload button on frontend. Here is my code that enqueues media and my script file function pc_scripts() { wp_enqueue_media(); wp_enqueue_script( 'pc_custom', ...
0
votes
0answers
211 views

Media library corrupted after upgrading to 4.9.6

I just upgraded WP to 4.9.6. My WP installation is on Windows 10 in a XAMPP installation, running as a virtual server on my laptop. I migrated this site from a remote LAMP server, with mostly ...
0
votes
0answers
540 views

Blank image thumbnails in media library

I copied one website to other domain. i am using avada theme in my new domain all images show as blank thumbnails in admin but in website all images are show i checked permission of all folder and ...
0
votes
0answers
16 views

Customize wordpress media uploader and attachment fields

I am trying to customize the wordpress media uploader. Example: Instead of two tabs(Upload files, Media library) I want to have one tab where Upload files comes before media library. But I don't want ...
0
votes
0answers
74 views

Using media_handle_upload with array

I have duplicable file inputs in a form, and I would like to upload them to WordPress media library using media_handle_upload. A form looks like this: <form class="form mt-5" method="POST" action=...
1
vote
1answer
34 views

Rest API rename media

I've been able to upload images using the REST API but the names are wrong right now and I was thinking to go through all of the products I have and rename the images. Since I have more than 500 ...
0
votes
0answers
14 views

Applying “Organize uploads into month and year” after they have been put into one folder

So I made the mistake, a long time ago on a old site, to NOT organize uploads into month and year. I now have 50k+ files in the same folder and it is causing big problems. Is there any way to sort ...
3
votes
0answers
38 views

How can I use the TinyMCE editor for the description field on a Media item?

When I view an image in my Media Library, the Description field textarea has a toolbar, but it's only for creating HTML tags. How can I get the TinyMCE wysywig editor to be used instead? I've found ...
1
vote
1answer
50 views

wp_get_attachment_image_src returns the wrong image

I uploaded an image my-image.jpg of dimension 1280x854, after that, I went to Dashboard > Media to crop it to 854x854. (Apply changes to All Image Sizes.) This however only change its thumbnail in ...
1
vote
0answers
159 views

wordpress media upload given An error occurred in the upload. Please try again later

i am using wordpress 4.8.3 . my website was working fine but when i moved it to another server , i saw some images of my posts are missing and when i am trying to reupload these images i faced another ...
2
votes
1answer
57 views

Upload thousands of images to WordPress without plugin?

Update: After debugging why the uploads were so slow, I found out the culript was the plugin WP Smush It. The question and answer bellow is the process of finding that out. I'm processing thousands ...
0
votes
0answers
36 views

Specify minimum image dimensions when using wp.media

I want to limit an image picker to images that are at least 650x650; how can I do this? I haven't been able to find any reliable documentation on wp.media. Current code: const media_buttons = ...
0
votes
0answers
16 views

Media library uploader ( set featured image, or general selecting image ) view in LIST, never GRID

In a WP installation I have to work on, I found that when I click on "Set Featured Image" on a post, the Media Library popup appears, with a grey thumbnail, but no thumbnail of the uploaded images. ...
0
votes
1answer
593 views

Pictures won't display in media library and also won't show preview when selected

I have done the plug in, check permissions (upload folder which contains files for the media contents is 755), clearing cache (there was none, apparently), disable any extra plug-ins, check and ...
0
votes
0answers
17 views

Media Library Upload not storing wp_postmeta

Environment is Wordpress 4.94 Multisite with numerous blogs up and running. This issue affects this blog only and is not affecting the others. When uploading an image or PDF (or other asset) to the ...
0
votes
1answer
15 views

File sharing platform for user contributions? [closed]

I am looking for a way to allow my visitors to share content between each other in an organized fashion. Essentially the ability to upload files or browse/download files that others have contributed. ...
1
vote
0answers
38 views

My Media Library is broken across all my subsites

After installing a bad beta plugin, my Media Library is broken across all my sub-sites. I’ve set my upload directory under Sites > domain.com > Edit Site > Settings > Upload Path to wp-content/blogs....