The first step is to add the image to the project.
This is done by using the "Assets" as found under the Advanced tab of the HTML5 output. Click the + button and select Add Files or Folders. In this example Add Files.
When added the images will appear in the Assets list.
The file path to these images will be assets/ then the file name.
So in this example
Code: Select all
assets/dog.jpg
Code: Select all
assets/cat.jpg
Code: Select all
assets/folder/image.jpg
Change the Polygon Hotspots ID, I am using "IP" (Image Popup) but can be anything.
The ID will be used later in the skin.
Leave type set to URL.
Then set a Title if you want to see a tooltip, example "The Dog".
In the description text field enter the path to the image: assets/dog.jpg
Open the skin editor and add a container, I am using the ID "Open Image Popup" but it can be any ID you wish.
Now add the Image Popup component from the components toolbox.
Select the Point Hotspot Template "ht_image" and copy its actions:
Now paste them into the container, "Open Image Popup".
Open the Mose Click Set Value action (1) and change the placeholder to $(hd), (2).
This placeholder looks at the path in the Polygon Hotspots Description text field.
Finally set up the Hotspot Proxy ID in the container, so under the Advanced tab enter the Polygon Hotspot ID which is "IP".
Any Polygone that will be used to open an Image Popup will need this ID.
This makes the connection between the Polygon Hotspots and the container.
When you click the Polygon Hotspot the actions in the container "Open Image Popup" will be actioned.
Regards,
Hopki