Web based family history software

Before asking for help please read "Requesting Help and Suggestions" by clicking on that tab above here.

Question Problem with displaying photos

  • allfred
  • Topic Author
  • Offline
  • New Member
  • New Member
More
3 weeks 3 days ago #1 by allfred
Problem with displaying photos was created by allfred
Hello everyone!
After importing data, gedcom file and multimedia, webtrees does not display images with polish characters ś ć ą. The others it displays correctly. How to fix it ? There are a lot of photos, and to change all the names and import again it will take me a few evenings.

Proxmox Virtual Environment home server
Webtrees 2.1.18 in docker

Please Log in or Create an account to join the conversation.

More
3 weeks 2 days ago #2 by Franz Frese
Replied by Franz Frese on topic Problem with displaying photos
what coding do you use for the gedcom file?
If you are a windows user, you can try open the gedcom file with notepad++, have a look at the bad characters and then save as UTF-8.
Normally UTF-8 should give a functional result.
as far as I remember, there is only a problem with utf-8 4 byte characters 

Please Log in or Create an account to join the conversation.

  • bertkoor
  • Offline
  • Platinum Member
  • Platinum Member
  • Greetings from Utrecht, Holland
More
3 weeks 2 days ago - 3 weeks 2 days ago #3 by bertkoor
Replied by bertkoor on topic Problem with displaying photos
Diacritical characters almost always give such headaches. The universal solution is UTF-8 encoding, but sometimes the encoding is done differently, for example with a variation of 8bit ASCII such as used in Windows: CP-1250 aka ISO-8859-2, or CP-1252 aka ISO-8859-1.

It could have gone wrong during import of the GEDCOM file in webtrees. You then have the option to select the encoding. But the GEDCOM file itself can specify an encoding itself in the header (first set of lines), to be specific the line that starts with "1 CHAR". Best is to take that value during the import.

There is also the possibility that your GEDCOM file has specific parts of it encoded differently. And it could also be that the files on the server where your GedCom Media Objects refer to have their file names encoded differently. This would be managed while uploading them to the server with FTP.

So you have some things to check...

stamboom.BertKoor.nl runs on webtrees v1.7.13
Last edit: 3 weeks 2 days ago by bertkoor.

Please Log in or Create an account to join the conversation.

  • allfred
  • Topic Author
  • Offline
  • New Member
  • New Member
More
3 weeks 2 days ago #4 by allfred
Replied by allfred on topic Problem with displaying photos
Before writing the post I already checked it. The gedcom file has UTF-8 in the header.
0 HEAD
1 SOUR Gramps
2 VERS AIO64-5.1.6-1
2 NAME Gramps
1 DATE 8 FEB 2024
2 TIME 21:53:06
1 SUBM @SUBM@
1 FILE E:drzewo 08.02.2024.ged
1 COPR Copyright (c) 2024 DP.
1 GEDC
2 VERS 5.5.1
2 FORM LINEAGE-LINKED
1 CHAR UTF-8

The file was edited in notepad++, I deleted paths to multimedia. When importing to webtrees, first the encoding was set to automatic. I imported a second time forcing the encoding to UTF-8 at import. it did not change anything. The only option is that when deleting tracks and saving notepad++ changed the encoding of the file. Is it possible ?

Proxmox Virtual Environment home server
Webtrees 2.1.18 in docker

Please Log in or Create an account to join the conversation.

  • bertkoor
  • Offline
  • Platinum Member
  • Platinum Member
  • Greetings from Utrecht, Holland
More
3 weeks 2 days ago - 3 weeks 2 days ago #5 by bertkoor
Replied by bertkoor on topic Problem with displaying photos
> 1 CHAR UTF-8

Nice indication, but not really a guarantee.

> I deleted paths to multimedia.

Do you still have the old GEDCOM file from before you did that edit? On the import dialog of webtrees there is an input field for exactly this: media path.

> saving notepad++ changed the encoding of the file. Is it possible ?

Notepad++ has that option, you could try that first. In the top menu select Encoding > Convert to UTF-8 and save the file. You may try with or without BOM (byte-order-mark) and if the option is greyed out then it already is detected as valid UTF-8.
Also do check whether the diacritical characters look ok or not in  Notepad++ before you save it. 

stamboom.BertKoor.nl runs on webtrees v1.7.13
Last edit: 3 weeks 2 days ago by bertkoor.

Please Log in or Create an account to join the conversation.

More
3 weeks 2 days ago #6 by fisharebest
Replied by fisharebest on topic Problem with displaying photos
Do you see the files in: Control panel -> Manage media ?

I guess that the files on the disk are not stored with UTF8 encoding.

If they came from windows, then perhaps they are UTF16?

Greg Roach - greg@subaqua.co.uk - @fisharebest@phpc.social - fisharebest.webtrees.net

Please Log in or Create an account to join the conversation.

  • allfred
  • Topic Author
  • Offline
  • New Member
  • New Member
More
3 weeks 2 days ago - 3 weeks 2 days ago #7 by allfred
Replied by allfred on topic Problem with displaying photos
Thanks for the reply.
In the meantime, I did some experiments. Of course I have the gedkom file, before deleting the paths in notepad++. I loaded gedkom in notepad++ , indicated conversions and writing in UTF8. Afterimport to webtrees no change. Well, I did another way. I imported the old gedcom file after exporting from Gramps and before editing in notepad++ into webtrees. I set the encoding on import to UTF-8 and entered what path it should delete. I still got 0404 in place of images with Polish characters.  There remains some problem on the server side. I send the files via Secure FTP, a plug-in for Total Commander. In the post-send window, already on the server side, the characters in the file names are displayed correctly. I'm running out of ideas.

 

Proxmox Virtual Environment home server
Webtrees 2.1.18 in docker
Last edit: 3 weeks 2 days ago by allfred.

Please Log in or Create an account to join the conversation.

  • allfred
  • Topic Author
  • Offline
  • New Member
  • New Member
More
3 weeks 2 days ago #8 by allfred
Replied by allfred on topic Problem with displaying photos
Only files without Polish characters in the name are displayed in the control panel.

Proxmox Virtual Environment home server
Webtrees 2.1.18 in docker

Please Log in or Create an account to join the conversation.

More
3 weeks 2 days ago #9 by fisharebest
Replied by fisharebest on topic Problem with displaying photos
So, I guess the encoding used by your local filesystem and the encoding used by your webserver are different.

I guess that when these files were transferred, the filenames were corrupted, and webtrees cannot see them.

Greg Roach - greg@subaqua.co.uk - @fisharebest@phpc.social - fisharebest.webtrees.net

Please Log in or Create an account to join the conversation.

More
3 weeks 2 days ago - 3 weeks 2 days ago #10 by Franz Frese
Replied by Franz Frese on topic Problem with displaying photos
I would have a look into the gedcom file, if you send me.
Have a look at the photos on the server. are they there , what name
Last edit: 3 weeks 2 days ago by Franz Frese.

Please Log in or Create an account to join the conversation.

  • allfred
  • Topic Author
  • Offline
  • New Member
  • New Member
More
3 weeks 2 days ago #11 by allfred
Replied by allfred on topic Problem with displaying photos
I followed the advice of fisharebest that the fault is not in the gedcom file but on the server side. The son was putting this server on Proxmox Virtual Environment. The server sits in my room, and the son manages it remotely. He has some other container services there, webtrees is just one of many, I don't know about it. But I called him to check the issue of character encoding at the container level. Is there any global setting of the whole container. It turned out that yes, he changed it to UTF-8 and it surprised me.
Until recently, I entered the data in Family Tree Builder. But it was garbage too much in the exported gedcom file. But there the file names the program gave were P1. P2, etc. And there was no problem with encoding, because there were no national characters in the names. Now I enter the data in Gramps. A little different philosophy, but I can see that it makes sense. And I can name the files any way I want, and this is where the problems started when importing. I truncate unnecessary paths in the gedcom file in notepad++, it is a very good program and if it says it encodes in UTF-8, it does. I still checked the SFTP plugin for Total Commander. Which I use to transfer files to the server. It turned out that the code page was not correct. If I uploaded files without Polish characters, it did not matter. And it was set to ANSI or ASCII. And in webtrees when importing, the encoding was set to automatic, and it worked.
[url=https://
[img
]SFTP[/url]
I converted to UTF-8 and son reconfigured the container. In webtrees I set the encoding to UTF-8 on import, and it works. The following message from my son.
It was an encoding issue on my setup.
Webtress is running in the docker container (which is inside LXC).
Default LXC encoding in my case was simply 'C'.

I regenerated and set specific locale (pl_PL.UTF-8) as default.
Now it works

I have another problem, in with some pictures. In the place of the thumbnail I have a 404, but when I click on it the photo loads correctly.
How to correct this ?

In the "Nearby events" tab, RIN MH:I251 appears with different numbers, without date or description. Can I painlessly delete this from the gedcom file in notepad++. Or rather disable somehow the showing of this in webtrees.

Thank you for your help

Proxmox Virtual Environment home server
Webtrees 2.1.18 in docker

Please Log in or Create an account to join the conversation.

More
3 weeks 2 days ago #12 by Franz Frese
Replied by Franz Frese on topic Problem with displaying photos
For a new question create a new topic.

Please Log in or Create an account to join the conversation.

More
3 weeks 3 hours ago #13 by fisharebest
Replied by fisharebest on topic Problem with displaying photos
> In the place of the thumbnail I have a 404, but when I click on it the photo loads correctly.
How to correct this ?

Use the developer tools in your browser.
Look at the HTTP headers for this 404 image
There will be one containing a helpful error message.

> Or rather disable somehow the showing of this in webtrees.

Control panel -> Family tree -> Privacy -> RIN/Record Identification Number -> Hide

Greg Roach - greg@subaqua.co.uk - @fisharebest@phpc.social - fisharebest.webtrees.net

Please Log in or Create an account to join the conversation.

Powered by Kunena Forum
}