Question How to mark individuals on group photo ?
- joeysun
- Offline
- Junior Member
I need it explained like I am 5 years old.
Doug 周
webtrees v2.1.20 at Our Family Tree (Jiapu 家譜/家谱)
PHP Version v8.1.x, LiteSpeed V8.1, MariaDB 15.1 | protected/'hindered' by ModSecurity
Please Log in or Create an account to join the conversation.
- NikitaRus
- Visitor
fisharebest wrote: Fixed - github.com/fisharebest/webtrees/commit/a...79671f07271428467f4e
I tested this using the image map on my own site fisharebest.webtrees.net/
Andreas wrote: Thank you for the answer. I'm late to reply.
But only today I tried to fix my small problem.
And it works. )
Thank you.....
Hello! Please tell us in detail how to make changes ? Unfortunately I am not an expert in programming Or tell us where there are similar examples . If I 'll take care of take off video lesson for everyone. Are you going to implement your changes to the main distribution webtrees?
Please Log in or Create an account to join the conversation.
- Andreas
- Offline
- Premium Member
First I'm not an expert in programming neither, but I found it neccessary to use the <map> tag in my HTML code.
The solution is to modify a core file of the webtrees installation. So this need to be readjusted after each version release of webtrees.
I suppose that it will not become a basic feature in future webtrees installation.
I agree with this because this kind of editor had been attacked frequently. So I prefere that we stay careful.
All was explained clearly in github.com/fisharebest/webtrees/commit/aa4af7e4b5d8515c758179671f07271428467f4e
You need to modify one file app/Module/CkeditorModule.php
by adding two lines and modifying one other line. After uploading the modified file to your server you will be able to insert <map> tags to your HTML-code everywhere in webtrees.
And this code will not be removed. )
The image map code itself has to be created by online or offline tools. These can be found easily by a google search.
---
An enhancement would be to add <map> functionality to CKEditor by adding a plugin.
But as I told above, I'm not a programmer.
Both MAUPILLÉ & RAUHUT families are using webtrees V2.1.18
Please Log in or Create an account to join the conversation.
- joeysun
- Offline
- Junior Member
Can you share a link or screen print on what you have done? You had mentioned in another thread that your former home page has these map tags. Have you've updated your home page yet? I might have navigated incorrectly on your site as I cannot find your images with the map tags.
Doug 周
webtrees v2.1.20 at Our Family Tree (Jiapu 家譜/家谱)
PHP Version v8.1.x, LiteSpeed V8.1, MariaDB 15.1 | protected/'hindered' by ModSecurity
Please Log in or Create an account to join the conversation.
- Andreas
- Offline
- Premium Member
The image I used for my first try is the tree on my homepage of wt.rauhut.eu
So feel free to have a look on my webtrees installation .
Try the links behind the text. They ar not jet full functionally.
And feel free to ask
Both MAUPILLÉ & RAUHUT families are using webtrees V2.1.18
Please Log in or Create an account to join the conversation.
- Andreas
- Offline
- Premium Member
before I explain it to others, please tell me, why the title property of <area> isn't used in your code example.
I added the property title to the list to obtain descriptions on mouseover beside the choosen topic.
And this works fine.
Both MAUPILLÉ & RAUHUT families are using webtrees V2.1.18
Please Log in or Create an account to join the conversation.
- fisharebest
- Offline
- Administrator
Because I forgot it
Fixed in github.com/fisharebest/webtrees/commit/f...359b6611add6d9efcfd0
Greg Roach - greg@subaqua.co.uk - @fisharebest@phpc.social - fisharebest.webtrees.net
Please Log in or Create an account to join the conversation.
- joeysun
- Offline
- Junior Member
That link helps. A picture is worth a thousand words. The tags nicely maintain their position when the screen is resized and on mobile platforms.
Doug 周
webtrees v2.1.20 at Our Family Tree (Jiapu 家譜/家谱)
PHP Version v8.1.x, LiteSpeed V8.1, MariaDB 15.1 | protected/'hindered' by ModSecurity
Please Log in or Create an account to join the conversation.
- NikitaRus
- Visitor
Andreas wrote: Hello Joeysun,
The image I used for my first try is the tree on my homepage of wt.rauhut.eu
So feel free to have a look on my webtrees installation .
Try the links behind the text. They ar not jet full functionally.
And feel free to ask
joeysun wrote: Andreas,
That link helps. A picture is worth a thousand words. The tags nicely maintain their position when the screen is resized and on mobile platforms.
I'm sorry, but I have not found the photos with marks on people. You could not write a person's name for whom this function is used ? Or give a link to the page in your tree .
Please Log in or Create an account to join the conversation.
- joeysun
- Offline
- Junior Member
I have a better idea of what you are doing. I am still looking forward to more details. I will need to read up on map tags their use in CKeditor. Maybe if you can be a bit more explicit on how you are doing this, especially for the noob I am.
Doug 周
webtrees v2.1.20 at Our Family Tree (Jiapu 家譜/家谱)
PHP Version v8.1.x, LiteSpeed V8.1, MariaDB 15.1 | protected/'hindered' by ModSecurity
Please Log in or Create an account to join the conversation.
- Andreas
- Offline
- Premium Member
if you want to see persons tagged have a look at this Picture and pass the mouse over the persons.
Joeysun,
an image map consists in a picture in a <img> tag and a <map>tag describing what to do on mouseover or click.
The code for the above example in Picture is easy. -have a look:
Both MAUPILLÉ & RAUHUT families are using webtrees V2.1.18
Please Log in or Create an account to join the conversation.
- NikitaRus
- Visitor
thanks for the clarifications ! But when I open your link I see a picture when I navozhu on her arm , there is not any reaction. I tried to press everywhere! I expect that will be active links such as the face area . Everything is up and running ? Maybe this feature is available only Authorizing users ?
Attachment not found
Please Log in or Create an account to join the conversation.
- bertkoor
- Offline
- Platinum Member
- Greetings from Utrecht, Holland
wt.rauhut.eu/individual.php?pid=26887I&ged=GAC.ged#stories
If you hover over a face, a tooltip will show the name of the person and if you click it will navigate to that person's page.
stamboom.BertKoor.nl runs on webtrees v2.1.20
Please Log in or Create an account to join the conversation.
- HRN
- Offline
- Senior Member
The Stories tab and HTML blocks on Andreas' fronpage are not available in all languages.
Try choosing another language to see the images
webtrees 2.1.22 at visitusinmaputo.com/webtree PHP 8.2.26
webtrees 2.2 on local Wampserver 3.3.7 PHP 8.4.0 MySQL 9.1.0
Please Log in or Create an account to join the conversation.
- Andreas
- Offline
- Premium Member
HRN is right. I didn't think about different languages.
HRN wrote: The Stories tab and HTML blocks on Andreas' fronpage are not available in all languages.
Try choosing another language to see the images
But that's the reason, why you can't see the example in your personal language.
Try one of the languages proposed by the system.
By the way it is very curious, that you are able to open the website in a language which isn't in the list.
In which language do you try ?
Both MAUPILLÉ & RAUHUT families are using webtrees V2.1.18
Please Log in or Create an account to join the conversation.
- Andreas
- Offline
- Premium Member
Once I read your message a second time I noticed that it's a reference to github where you fixed it.
fisharebest wrote: > why the title property of <area> isn't used in your code example
Because I forgot it
Fixed in github.com/fisharebest/webtrees/commit/f...359b6611add6d9efcfd0
Does this mean, that the <map> tag may be or will be allowed in future releases of webtrees ?
Both MAUPILLÉ & RAUHUT families are using webtrees V2.1.18
Please Log in or Create an account to join the conversation.
- fisharebest
- Offline
- Administrator
Yes
Greg Roach - greg@subaqua.co.uk - @fisharebest@phpc.social - fisharebest.webtrees.net
Please Log in or Create an account to join the conversation.
- Sodan
- Offline
- New Member
I always wanted something like this is webtrees, but I never thought to use CKeditor to achieve it.
Thank you for the idea, your code, you examples and your fixes
I set it up on my site, but the image was too big. I didn't want to set a fixed width for the image, it had to scale to every screen. To do this, in the <img> tag add
But now the coordinates of the image map were all but accurate. So I found a JS library that update the coordinates as the image is scaled : github.com/davidjbradshaw/image-map-resizer . Download it on you server (in /assets for me), then add this after your closing </map> tag :
To keep the <script> tags in CKeditor, I had to add "script[type,src]" in CKEDITOR.config.extraAllowedContent (file CkeditorModule.php)
You can see the result here : www.genealorand.com
Every face has a name at hovering, some have a link.
The full source code is :
webtrees 2
nginx, PHP 7, MariaDB, HTTP/2
genealorand.com
Please Log in or Create an account to join the conversation.
- Sodan
- Offline
- New Member
You can see the result in the attachment or on my site.
To achieve this, I made something ugly (Greg, or anyone else, if you have a better way to do this just let me know) : I modified app/Controller/PageController.php by adding 3 lines :
This way images map work on the Home page, as well as on the Story pages, and, as far as I know, with every theme.
Since all the scripts are handled by the function pageFooter(), it is no longer necessary to add "script[type,src]" in CKEDITOR.config.extraAllowedContent (file CkeditorModule.php).
To make the highlight works, just add this to your <img> tag :
Now, all you need to write in Ckeditor is :
webtrees 2
nginx, PHP 7, MariaDB, HTTP/2
genealorand.com
Please Log in or Create an account to join the conversation.
- NikitaRus
- Visitor
Bert хор, Thank you! Your link works! I understand how it works .bertkoor wrote: @NikitaRus: judging on the absence of text above the picture you're not viewing the correct page. Should be this one:
wt.rauhut.eu/individual.php?pid=26887I&ged=GAC.ged#stories
If you hover over a face, a tooltip will show the name of the person and if you click it will navigate to that person's page.
Andreas wrote: @NikitaRus
In which language do you try ?
I automatically open a window in Russian (probably based on data from cookies)
Please Log in or Create an account to join the conversation.