Questions tagged [uploads]

This include all question concerning the process of uploading file, whether from the WP Admin Pages or from a front end editor.

Filter by
Sorted by
Tagged with
0
votes
0answers
15 views

Force documents to appear in Featured Image dialogue

Having a perplexing issue... ...for a custom post-type called 'Resources' I used the 'Featured Image' or 'thumbnail' function within WordPress to allow users to attach documents to 'Resources'. The ...
0
votes
0answers
40 views

what functions to use to resize images and create DB metadata for them after/during upload?

I am working on my first script to create a WP post with images and upload those images to the uploads folder. I am clear about wp_insert_post and was able to upload an image to the server with ...
0
votes
0answers
15 views

Merge Multisites with Shared Network Media Library

So have a multisite setup which no longer needs to be a multisite but I'm left with a bit of a mess since I used Network Media Library plugin to host images for all sites on the network. I'll try to ...
0
votes
0answers
11 views

How to create ACF repeater from REST API? [closed]

I want to create repeater childrens fields from REST api and JSON? How is that possible? My goal is to "tell" acf repeater fields to create my n number of repeater subfields. Secound, bonus question:...
0
votes
0answers
6 views

Upload wp-content/upload to other Host Storage via FTP [closed]

i Have file storage for upload Image My Website www.site.com and my Storage FTP Host cdn.site.com i want automatic upload via FTP automaticly in other Host Just Upload image . i use two plugin but ...
0
votes
0answers
21 views

the content of the uploads folder gets deleted periodically, how to figure out what causes it?

The entire content of my uploads folder gets deleted periodically. every few days, I'm not sure when exactly. How can I debug what causes this? My set up is complex: around 10 plugins, some custom. ...
0
votes
0answers
15 views

Snippet overwrite media files?

I'm looking for a snippet that will overwrite media files. Example: There a audio file called Dogpark.mp3 uploaded to wordpress. The next week I have a few file called Dogpark.mp3 which I want to ...
0
votes
0answers
12 views

Syncing Avatars across multisite

There's gotta be a way. I have tried a bunch of different multisite sync plugins and they sync users and roles just fine (even paid for plugins to do so)....but avatars don't sync. My registration ...
1
vote
1answer
13 views

Image upload via FormData API and AJAX is not working ($_FILES always empty)

When I try to do what's mentioned in the title, my requests all work (nonce check passes, and server response 200 receveived, and server - script also working properly). My problem is that I cannot ...
1
vote
0answers
14 views

Select multiple images from custom field

I've created a custom field with image select/upload. This only makes me select one image, but I want to be able to select multiple images. Been looking for this quite some time but still not managed ...
0
votes
2answers
14 views

Moving Existing images from custom directory to WP's upload directory

I have a site I'm working on and when it was developed they had all the media uploads go to folder called /assets/ in the root of the WP install. This is being done via: define('UPLOADS', 'assets'); ...
1
vote
0answers
27 views

How to upload a file to a folder named after the user_id via plugin

I'm trying my hands at my first plugin, nothing fancy just want to grab the user_id, create a folder for each user and let the user upload an image. I know my code can't be completely wrong, because ...
0
votes
0answers
15 views

Upload Image through pods form to create custom post type

I'm using the pods framework for all custom post types on my wordpress site. The customer I'm building the website for wants to have a form, where his affiliates can submit their company and some ...
0
votes
0answers
38 views

How to restrict access to wordpress upload by specific user

I've added this to the downloads.php in woocommerce my account: <?php $current_user = wp_get_current_user(); $file_for_client = get_field('upload1232423', $current_user); if( $file_for_client ) :...
0
votes
0answers
23 views

SVG (file) Animation Not Working on Safari

I'm working on a WordPress site that's using Block Styles. We have a few blocks that have custom style templates that users can select when they add a new block. One template has an image that is ...
0
votes
0answers
22 views

Generate and upload screenshot as featured image for user-submitted post

I have a website where users can submit posts (the posts must have a URL of a website). I would like to use a screenshot of that URL to be the featured image. I have used this code to generate the ...
1
vote
0answers
17 views

How to get the upcoming post ID from front end?

Searching with "Next Post ID" is giving me the Previous/Next Post Navigation, but my question is not related to that. In WordPress Admin panel, when we're attempting to create a new post the post is ...
-1
votes
0answers
12 views

Setting up a wordpress blog for homework submission

I am trying to setup a blog for 2 purposes: 1) For students to hand in their work at specific dates 2) To act as a documentation device for me to preview student's work over the years. The layout I ...
0
votes
2answers
18 views

Wordpress shows different upload_max_filesize than php.ini setting

I have php.ini files in the following directories of my WordPress installation: /wp-admin /wp-content / (where there wp-config.php lies) In all of them I set upload_max_filesize = 640M; - 640MB is ...
0
votes
0answers
9 views

Uploading multiple images from url list with php - Wordpress

I have a list of xxxx image urls. 1- I want all images from a field where I can enter a url list to be uploaded to the wordpress media library. 2- The attachment ids of all uploaded images will be ...
0
votes
0answers
8 views

Video upload fails at 83% every time

I have my upload threshold set to 256M. Every time I try to upload a file (97Mb), it stalls at 83% and fails. I can't find a single piece of information on this and it can't be unique. I have no ...
0
votes
0answers
9 views

Failed to upload pa_color color-name

I have installed WordPress and installed Konstructo - Construction and Architecture WordPress Theme. I have followed the steps given in the theme documentation. Then I click the Import Demo settings ...
0
votes
0answers
11 views

Show image in wordpress media and assign it to post from bbdd

I have tried to do this in many ways but i just cant figure it out... The process i am hoping for is: Upload image to ftp wordpress upload folder (with year and month, as wordpress usually does). ...
0
votes
0answers
11 views

Make media fields required on upload in WordPress

I am trying to force the user to type in a caption (and/or the other fields) when they upload an image. That way they can't forget to put in the copyright for the images. Is there a hook and how can ...
0
votes
0answers
29 views

How to move files to media library/upload directory?

I made a mistake uploading my files and I don't want to re-upload it again. I wanted to make my files available to download by any users, and in this tutorial, it shows how to do that. Unfortunately, ...
0
votes
0answers
16 views

Could creation of various image sizes cause slow form submission response?

when I submit an image to WP media gallery or trough various plugins, the process takes quite some time to complete. A 4MB image takes like 2-5 seconds to upload (got fast connection), then there is ...
0
votes
1answer
152 views

Unable to upload images into the media library

After moving my website from one host to another I am unable to upload new pictures in my media library either by directly using the Media > Add New menu or by adding media from within the new post ...
0
votes
0answers
22 views

unsharp thumbnails after uploading image

I googled for a whole day and didn't found a solution. I tried a lot of plug ins and so on, but didn't get it. If I upload for example that image here: https://deermylove.com/wp-content/uploads/...
1
vote
0answers
8 views

Loose images in uploads folder

thanks for viewing. The uploads folder of this site has hundreds of loose images after someone turned off the folder structure for a year. These images are being used in older posts so not ideal just ...
0
votes
0answers
13 views

Multisite redirect upload path from server 2 to server 1 with haproxy

I have 2 servers with Wordpress MultiSite installed. I also have a server with haproxy installed. haproxy server: 10.10.10.10 site - 1: 10.10.10.11 site - 2: 10.10.10.12 All requests coming to the ...
1
vote
1answer
17 views

Plugin upload to install

I am getting Please select a file issue while trying to upload a plugin ZIP file.
1
vote
0answers
12 views

How to upload images from wordpress front-end (the first image must be thumbnail and the rest without first must be in gallery woocommerce product)

How to set first image from $_FILES array to product woocommerce post thumbnail and the rest put into woocommerce product gallery. I have this code: if ( ! empty( $_FILES['thumbnail'] ) ) { ...
0
votes
0answers
9 views

upload a file with other information as separate requests to backend

I am building a backend which allows the user to upload a csv along with some other information. My current approach is using a multipart form in which user can upload the file and the data together. ...
0
votes
0answers
26 views

How to delete original image file after upload and resize

When I upload an image named image.jpg, Wordpress creates image-150x150.jpg. How can I delete image.jpg and keep just the image-150x150.jpg in function.php, because I want to optimize my disk space ...
0
votes
0answers
17 views

Is there a way to make the default image sizes refer to the full-sized file?

I'm offloading all media files to S3 and serving them through Imgix, who perform all compression/resizing on the fly. To prevent WP from producing extra files, I've removed the default image sizes ...
0
votes
0answers
10 views

Upload array of images from external api to media library

I'm new into wp and I'm trying to upload an array of Urls into the wordpress media library programmatically. I do have a call to an external api and I save the images Urls into an array. <input ...
0
votes
0answers
10 views

Powerpress upload a podcast without creating a post for it

Hi Im trying to upload a podcast using PowerPress but without creating a post for it on website as the podcast will be listened to using podcast.player. I don't mind creating the page as private but I ...
0
votes
1answer
43 views

Restrict Image Uploads to a Certain File Type

I'm a content manager and want to make sure that all images uploaded by my writers onto WordPress are in JPEG format, rather than PNG as this slows the site down. Is there a way for me to check the ...
1
vote
1answer
53 views

remove_accents does not seem to work (when used inside sanitize_file_name filter)

I am trying to automatically remove accents from uploaded files through WP administration. This is my current approach (functions.php): add_filter('sanitize_file_name', function($filename) { ...
0
votes
0answers
22 views

Convert GIF to MP4 on image upload and serve URL to converted file

What hook would I use to tap into newly uploaded files for converting GIFs using ffmpeg to MP4? New to plugin development.
1
vote
2answers
19 views

How can i attach the attachment-ID to the user profile image?

I have used custom php form for uploading image via ajax. And has successfully uploaded the image and getting the attachment id & the image url also, Is there any way to attach the attachment id ...
0
votes
0answers
26 views

Front end Ajax custom file uploads with multiple file return 404 not found, single file upload working perfectly

in the templete file I gave the below code, <input type="file" name="files[]" id="files" multiple onchange="javascript:updateList()"/> <div id="...
0
votes
0answers
12 views

Hook for upload completion?

I'm trying to execute a command after a file has uploaded, but I'm not getting very far. wp_handle_upload_prefilter fires before the file is fully written to disk and moved from its temporary location,...
1
vote
1answer
47 views

I made a website using WordPress, but the server is ColdFusion, how can I make it work?

I made a website using Wordpress, and when it came time to turn it live, I was told the site server uses Coldfusion. I don't know anything about it but they claim it wouldn't work. Is there anything I ...
1
vote
1answer
36 views

How to replicate Media Library “Add New” on Plugin Settings Page

When you click the Add New button next to the Media Library page title... It opens the Drop files to upload template... I want to replicate that on my plugin settings page. Ideally using default WP ...
0
votes
0answers
14 views

Is there a way to enhance image uploader with crop option?

If you use one of the default themes you might find that the custom header upload or logo uploader in customizer allows you to crop right in upload screen. Is there a way to do that in all upload ...
0
votes
1answer
34 views

My image rotate 90 degree

For some reason, my pictures after being published on the site are turned upside down by 90 degrees, and everything looks fine in the admin panel. How to fix it ?
0
votes
1answer
95 views

Can't upload Images to Wordpress - Error 500 Response

I'm having a really frustrating issue whereby I can't seem to upload any images to Wordpress in a post content or via the browser uploader, multi-file uploader. When uploading a single image directly ...
0
votes
1answer
35 views

Change Image folder Locations

I currently have a site that has a number of custom post types. I want to ideally have the following structure /wp-content-uploads/posttype/postid/xxxx.jpg. All the images are attachments of the posts ...
0
votes
0answers
29 views

Image upload in custom theme settings page

I need to upload a logo image and set other options on a custom settings page. I can't retrieve the URL and upload the custom image, what is wrong with my code? <?php /*** New menu item ***/ ...

1
2 3 4 5
36