Page 1 of 1

iframe gallery or embedded Object projects not working

Posted: Wed Jul 14, 2021 2:57 pm
by Hopki
Hi,
In one of our webinars we looked at using Pano2VR to build a gallery, then the outputs to be used inside a tour.
Here is the link to the webinar, Embedding Content in Pano2VR Projects.
In WordPress, the iframe can not find the galleries.

This issue is also true when embedding anything using an iframe including an Object2VR project.
You may or may not know WordPress does some odd things with file paths, so we have a placeholder $(r) to fix the path issue.
This placeholder can be used to fix the galley as well.

The iframe code would look like this:

Code: Select all

<iframe src="assets/$(hd)/index.html" width="100%" height="100%" allowfullscreen="true" mozallowfullscreen="true" webkitallowfullscreen="true" frameborder= "0" ></iframe>

So you can see the path is src="assets/...

The placeholder $(r) gets inserted just before the word assets, so it looks like this:

Code: Select all

<iframe src="$(r)assets/$(hd)/index.html" width="100%" height="100%" allowfullscreen="true" mozallowfullscreen="true" webkitallowfullscreen="true" frameborder= "0" ></iframe>

The gallery or Object will now show in WordPress.
The placeholder does not do anything outside of WordPress so you can leave it in there.
In fact, if you look at the components, for example, the image popup you will see it used in the file path to the image.
Regards,

Re: iframe gallery or embedded Object projects not working

Posted: Tue May 16, 2023 10:52 am
by MThieme
Hello,

the placeholder must also be entered in the path of the images in the "gallery skin".
So under: "external image" -> "external URL" insert the placeholder $(r) in front of "assets".
2023-05-16_10h47_42.png
2023-05-16_10h47_42.png (24.92 KiB) Viewed 8300 times
Regards
Matthias