Have your say in Community Polls: What was/is your greatest motivation to start your own business?
Our Partner & Developer boards on the community are moving to a brand new home: the .dev community forums! While you can still access past discussions here, for all your future app and storefront building questions, head over to the new forums.

Embed a local (WebGL) page as an iframe - 400 Bad Request

Embed a local (WebGL) page as an iframe - 400 Bad Request

TenEyes
Visitor
2 0 0

Hi everyone,

I was looking everywhere but didn't get a solution yet.

I am trying to embed a WebGL page as an iframe into my shopify app. I created the shopify app with app-bridge with the shopify CLI as a react app.

The WebGl page is in the same directory as my shopify app. Everytime I try to load the html into an iframe I get a "400 - Bad Request" error and the following output in my console:

TenEyes_0-1617699532563.png

I also get this when loading just a test.html with only text. This is the iframe code I am using:

<Iframe url="test.html"
			width="450px"
			height="450px"
			id="myId"
			className="myClassname"
			display="initial"
			position="relative"/>

Sometimes the app first loads in a new window, before returning to the admin panel and embedding the app. When this is happening, I can shortly see that the html is correctly loading. So I am assuming that's something connected with app bridge.

I would be happy if someone could help.

Thanks in advance!

Reply 1 (1)

Morek
Shopify Partner
835 73 179

Hi @TenEyes 

Hope you're having a great day!

Did you finally find a solution?

If you're looking for a Shopify developer or just want to connect, don't hesitate to reach out!
Portfolio: https://mmorek.com/
LinkedIn: https://www.linkedin.com/in/mmorek
WhatsApp: Whatsapp me!