Uploaded image, but not showing

I have a reasonably fresh WordPress install on my Ubuntu Linux server and I uploaded an image to it for use in a blog post. I checked the path in WordPress settings and I checked the contents on the server:

$ ls -l /srv/www/wp-uploads/blog.linformatronics.nl/2013/01
total 320
-rw-rw-r-- 1 www-data www-data 22033 Jan 19 10:23 ccs5licence1-150x150.png
-rw-rw-r-- 1 www-data www-data 64195 Jan 19 10:23 ccs5licence1-300x214.png
-rw-rw-r-- 1 www-data www-data 22033 Jan 19 10:19 ccs5licence-150x150.png
-rw-rw-r-- 1 www-data www-data 71973 Jan 19 10:23 ccs5licence1.png
-rw-rw-r-- 1 www-data www-data 64195 Jan 19 10:19 ccs5licence-300x214.png
-rw-rw-r-- 1 www-data www-data 71973 Jan 19 10:19 ccs5licence.png

The files are actually uploaded through WordPress, so it has write access to the filesystem/directory.

But when I try to use it in a blog post it shows a broken image and when I point the webbrowser directly to the image it throws an error 404 page: https://blog.linformatronics.nl/wp-uploads/2013/01/ccs5licence1.png

From the settings => media page in WordPress:

Uploading Files
Store uploads in this folder /srv/www/wp-uploads/blog.linformatronics.nl    
Full URL path to files       http://blog.linformatronics.nl/wp-uploads  

I’m fairly new to WordPress, so I still need to find my way around a bit.

4 Answers
4

I think the problem is that you are storing your images in /srv/www/wp-uploads/blog.linformatronics.nl/2013/01 but your link to the image is https://blog.linformatronics.nl/wp-uploads/2013/01/ccs5licence1.png.

What you need to do is tell wordpress to store the images in /srv/www/blog.linformatronics.nl/wp-uploads/2013/01.

What your trying to do, it seems, is store images in wp-uploads/blog.linformatronics.nl but the folders should be swapped. It’s the website name and then the wp-uploads folder.

Leave a Comment