Printable Version of Topic

Click here to view this topic in its original format

HTMLHelp Forums _ General Web Design _ iframe Not Working

Posted by: orcainbox Dec 11 2019, 02:40 AM

I am trying to insert an iframe but its not working.

Whats wrong with my code?

<div>
<p style="text-align:centre;">
<iframe width="560" height="315" src="https://www.instagram.com/p/B50hlJiH585/?utm_source=ig_web_button_share_sheet" frameborder="0" allowfullscreen></iframe>
</p>
</div>

http://www.orcaaccounting.com/helloFriend.html

Posted by: Christian J Dec 11 2019, 06:43 AM

QUOTE(orcainbox @ Dec 11 2019, 08:40 AM) *

I am trying to insert an iframe but its not working.

Maybe Instagram does not permit some URLs to be framed? Are you using the URL Instagram itself recommends for embedding?

QUOTE
Whats wrong with my code?

Nothing relevant (but the correct spelling in CSS is "text-align: center").


Posted by: orcainbox Dec 11 2019, 09:38 PM

thanks for the er nor re in centre. In Canada we spell it centre nor center.

I removed the instagram link and replaced it with a you tube link but same thing, no iframe shows up on the page.

Posted by: pandy Dec 12 2019, 07:50 AM

Now nothing loads. Your server seems to be down.

Posted by: orcainbox Dec 13 2019, 08:27 PM

QUOTE(pandy @ Dec 12 2019, 07:50 AM) *

Now nothing loads. Your server seems to be down.


No server is up,
http://orcaaccounting.com/helloFriend.html

Posted by: pandy Dec 13 2019, 08:38 PM

So you've changed to Youtube. I think it'll work if you use the whole iframe code youtube wants you to use. At least that works locally. I don't know what the attributes you've excluded do, but they do seem to do the trick.

Posted by: orcainbox Dec 14 2019, 01:56 PM

This code worked

[<iframe width="560" height="315" src="https://www.youtube.com/embed/riFyKUyGb4k" frameborder="0" allowfullscreen></iframe>]

w00t!

Posted by: pandy Dec 14 2019, 09:11 PM

But that's what you had when I looked and then it did not work. It didn't work locally either.

Posted by: CharlesEF Dec 15 2019, 01:48 AM

The new code doesn't have the query string part.

Posted by: pandy Dec 15 2019, 12:45 PM

There wasn't a query string in the old either. I still have it. It's the same as now.

CODE
<iframe width="560" height="315" src="https://www.youtube.com/watch?v=riFyKUyGb4k" frameborder="0" allowfullscreen></iframe>


I changed that to the full youtube tag and then it worked for me.

CODE
<iframe width="560" height="315" src="https://www.youtube.com/embed/riFyKUyGb4k" frameborder="0" allow="accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture" allowfullscreen></iframe>

Powered by Invision Power Board (http://www.invisionboard.com)
© Invision Power Services (http://www.invisionpower.com)