Change scene when click a button from iframe

I have 2 buttons in an iframe with code
window.parent.document.showSceneNamed(‘scene1’); //
but it did not work.
Help me, please
This is my file. (1.5 MB)

There’s a few things that are wrong. Note that a hype document is different than the browser’s document variable. You get at Hype documents via the HYPE.documents array. The second issue is in the scene2 code, the closing tick mark is actually an apostrophe/smart quote: ’ vs ’, which isn’t valid code. What you’ll want to use is this code:




It works perfectly.
Thank you so much jonathan.
You saved my life.

1 Like