I cannot upload images to post or the media library in wordpress

admin2025-06-03  4

Whenever I try to upload featured image for a new post or edit featured image of the older post, the following errors comes up:

An error occurred in the upload. Please try again later.

Here I have attached screenshots,

Whenever I try to upload featured image for a new post or edit featured image of the older post, the following errors comes up:

An error occurred in the upload. Please try again later.

Here I have attached screenshots,

Share Improve this question asked Feb 2, 2019 at 12:47 Sujal PaudelSujal Paudel 11 bronze badge 2
  • Check in the Browser console, there should be an error. That will tell you about it is. Post the error here. – Lucien Dubois Commented Feb 2, 2019 at 15:07
  • Also, add define( 'WP_DEBUG', true ); and define( 'WP_DEBUG_LOG', true ); to your /wp-config.php above the line that says "Stop editing". This will create a file in /wp-content/debug.log that may have some errors after trying to upload again. – phatskat Commented Feb 6, 2019 at 6:46
Add a comment  | 

1 Answer 1

Reset to default 0

Make sure the wp-content/uploads directory is writable.

In Ubuntu, open the terminal, then type

chmod 777 -R /var/www/html/wordpress/wp-content/uploads

Adjust that command to your WordPress installation directory. Then, try again.

转载请注明原文地址:http://conceptsofalgorithm.com/Algorithm/1748949991a315085.html

最新回复(0)