Problem with images

This is the right place to report general bugs, make suggestions or ask for help.
Post Reply
winddrifter
Posts: 5
Joined: Wed Apr 24, 2024 10:01 pm

Problem with images

Post by winddrifter » Wed Apr 24, 2024 10:29 pm

I maintain a mirror of my online blog on my local PC. I have a recent blog entry where the images will show on my local computer, but not on the hosted version. Both are using the latest version (1.3.dev [master]). Php 8.1.17 at home, 8.0.29 on the hosted (problem post) version. The images were showing up on the hosted version, but then something changed. I see links to the images, and they show the correct path.
-Permissions are the same for every folder/image in the images folder: 0776
-None of my other posts have a problem with images
-I deleted the images for this post and recopied them, along with the post entry text, from my home (working) version
-If, on the hosted version, I change an image property (such as width=xxx), the thumbnail image is regenerated in the .thumbnail sub-folder, so the image url is correct and the image is present.
-if I click on the image link I get a message "Image could not be loaded" at the top left corner I see something like 5/18, where it is the 5th image out of 18 in that image sub-folder. So the number of images is known, and which of the images it is.
-when I try to open link in new tab, I get a browser message saying I do not have permission to access that document.
FPImageProblem.png
FPImageProblem.png (74.96 KiB) Viewed 37016 times

User avatar
fraenkiman
FlatPress Coder
Posts: 502
Joined: Thu Feb 03, 2022 7:25 pm
Location: Berlin, Germany
Contact:

Re: Problem with images

Post by fraenkiman » Thu Apr 25, 2024 6:11 pm

Hello @winddrifter,

welcome to the FLatPress support forum.
There are several possible causes of the error:
- The owner is not www-data
- The "Blogbase URL" is not correct (admin area, "Configuration" menu)

- Tests have shown that file permissions should have octal 0666 and directory permissions octal 0777

- It can't hurt to recreate the index in the admin area in the "Maintain" menu and then empty the theme and template cache.
- Please also clear the browser cache
- Deactivate subsequently installed browser extensions
- Check whether the problem also exists with another browser.

I recommend that you update FlatPress to 1.3 release or to 1.3.1 dev [master] for local testing.

Please report whether these measures have been successful.

With best regards
Frank
:pencil: You are strong in PHP and Java Script? :point_right: Then help us to improve FlatPress. :point_left:

:exploding_head: Looking for ideas, templates, examples and answers to frequently asked questions?
:bulb: You'll find it here.

My :de: FlatPress-Blog: https://frank-web.dedyn.io, synced with :elephant: Mastodon

eagleman
Posts: 249
Joined: Sat Mar 02, 2019 12:10 pm

Re: Problem with images

Post by eagleman » Thu Apr 25, 2024 7:12 pm

Probably you had my same problem.
Try to put the inages folder into fp-content.
In this way you can use the same syntax when you write the link or you can use the dropdown menu into the editor.

winddrifter
Posts: 5
Joined: Wed Apr 24, 2024 10:01 pm

Re: Problem with images

Post by winddrifter » Fri Apr 26, 2024 1:37 am

fraenkiman wrote: Thu Apr 25, 2024 6:11 pm - Tests have shown that file permissions should have octal 0666 and directory permissions octal 0777
- It can't hurt to recreate the index in the admin area in the "Maintain" menu and then empty the theme and template cache.
Please report whether these measures have been successful.
With best regards
Frank
That was very useful! I had tried the 'restore file permissions' and rebuild index under Maintain, but without joy. The file permissions gave me an error about not being able to reset to 0776, but I ignored it because all of the files/folders were 0776. Now that I've used the permissions you gave, everything is working.

My home install is Windows, so those file permissions are not a problem, but now I know what they should be.

Thanks!

Richard

Post Reply

Who is online

Users browsing this forum: No registered users and 0 guests