Help on Mouseover in SVG

Submitted by jordibabot on October 22, 2024
So I have this new quiz

https://www.jetpunk.com/user-quizzes/322511/municipis-costaners-de-les-comarques-barcelonines-catalunya

about the municipalities of Barcelona province.

I would like the name of the correct municipality to appear below the map when I mouse over, as in many SVG quizzes.

What am I doing wrong?

Thanks in advance

6 Comments
+2
Level 78
Oct 22, 2024
I'm not sure why that isn't working. It's a bit odd because the municipalities light up, but don't show up when the cursor is over them.

I'm not very good with SVGs, but if you want, you can add me as a collaborator and I can take a look. (Once again, I'm no expert so I may not be so helpful)

+1
Level 69
Oct 23, 2024
Done!
+1
Level 78
Oct 23, 2024
Thank you. I took a look at the svg file and tried a few things, but it didn't seem to work. I'm sorry I couldn't figure it out. It's odd that it's doing that, but I don't know enough about svg formatting and how JetPunk reads them to know what's going on
+1
Level 69
Oct 23, 2024
Found the problem, read below.
+1
Level 69
Oct 23, 2024
Ok the problem was in the layers, the municipalities layers had to be on the top of the SVG, above all the other kind of objects/layers.

The problem now is when I mouseover and stay in an object, it pulls out the answer, as the name is in the title of the object. I will have to remove the titles in the SVG.

Maybe the Quizzmaster should allow to "hide titles on mouse over" with a checkbox in SVG options.

+2
Level 78
Oct 23, 2024
Great work in figuring it out!

Eres un crack