Instagram embed box not loading embed code... anyone know a workaround? - instagram

I am trying to copy the embed code from a single Instagram reel by clicking the ... menu and clicking Embed. However, the code never loads and I get this screen. Anyone know a workaround to embed an Instagram reel on a website? The specific reel is: https://www.instagram.com/reel/Cd56By5FxBF/
See screenshot for what loads when I try to use to embed function on instagram. I have tried on multiple browsers.
Thanks

The integration code is made up of two elements. A long <blockquote> followed by a short <script>.
The <script> element should look something like this:
<script async src="//www.instagram.com/embed.js"></script>
Just add https: to the value of the src attribute, thus:
<script async src="https://www.instagram.com/embed.js"></script>
And everything should be working fine.

Related

How to redirect to a website in Godot Web

I'm planning on trying to see if it's possible to make a website in Godot(Yes, I know I shouldn't I just want to try just to try). I thinking about and looking over the features I need and I have one problem.
I just need a way for a person to press a button and get redirected to my itch games. I don't care if it creates a new tab or changes the current tab. Thank you for any help.
If you dont export to web you can call
OS.shell_open("url")
Sadly this does not work in an html export. A solution I found for myself is the JavaScript Interface. As the name suggested it allows you to execute Javascript.
So to open a URL you could connect the pressed signal of a button to something like this:
if OS.has_feature('JavaScript'):
JavaScript.eval("""
window.open('https://google.com', '_blank').focus();
""")
This will open a new tab in the active browser.
I also found an article on the godot site, basically asking the same question (https://godotengine.org/qa/46978/how-do-i-open-richtextlabel-bbcode-links-in-an-html5-export). Here they tried to use an RichTextLabel with BBCode.
The solution did not work for me, when I tested it, though.
As pointed in the comments you can try OS.shell_open, for example:
OS.shell_open("https://example.com")
That only works if it is not an HTML export.
Your other alternative is to eval JavaScript, for example this navigates the current tab:
JavaScript.eval("window.location.href='https://example.com'")
Which only works if it is an HTML export.
Since that only works for an HTML export and the other does not work on an HTML export... If you need both you can do this:
if OS.get_name() == "HTML5":
JavaScript.eval("window.location.href='https://example.com'")
else:
OS.shell_open("https://example.com")
See also Close a game in Godot.

Multiple iframes on the one page with iFrame Resizer

The docs for iFrame Resizer say:
When the resizer does not work using multiple IFrames on one page, make sure that each frame has an unique id or no ids at all.
I have chosen to give no ids to the iframes. My code is shown below. It works but I wanted to confirm that I am doing everything correctly. Specifically, I am calling iFrameResize() only once and with no arguments - is that ok?
<iframe src="https://example.com/frame1" scrolling="no"></iframe>
<iframe src="https://example.com/frame2" scrolling="no"></iframe>
<script src="https://cdnjs.cloudflare.com/ajax/libs/iframe-resizer/3.5.15/iframeResizer.min.js"></script>
<script>iFrameResize()</script>
Note: #david_bradshaw, I decided not to use ids, because in that case it was not clear how to call iFrameResize() - do we need to call it once for each iFrame? Please clarify. TIA
I suggest putting ID's in.
Not sure if this will help.
Requires: iframeResizer.contentWindow.min.js to be loaded into the target frame.
Reference: cloudflare.com (21-Jan-2018)
Example
<style>iframe{width: 1px;min-width: 100%;}</style>
<iframe id="myIframe" src="http://anotherdomain.com/iframe.html" scrolling="no"></iframe>
<script>iFrameResize({log:true}, '#myIframe')</script>
Reference: davidjbradshaw (21-Jan-2018)
NOTE: ID Being used to sent to resizer method.

Google Translate Drop Down

i have purchased a website template and i need help concerning the website translator using google translate.
The translate works well but after selecting a language, a google drop down appears and when i scroll down, it still appears and hides my main header titles.
Can something be done like removing this drop down when i translate a language or can someone suggest me another method.
Thanks a lot.
The problem is the the contents in this bar are inside of an iframe, So you cant use javascript to trigger the close button.
Solution
Once the user chooses a language the an iframe with a class named 'goog-te-banner-frame'
is added.
You can use javascript to detect if it present and hide it
$(document).ready(function(){
if($('.goog-te-banner-frame').length > 0){//check if the iframe exsits
$('.goog-te-banner-frame').css('display','none');
$('body').css('top',0);//google adds top to the body so the bar wont cover website content
}
});
because this code uses jquery. make you sure you load it like this:
<script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.4/jquery.min.js"></script>

phantomjs // render webpage from give dom

is there any chance to render/process a webpage just from the given DOM?
At the moment we can use page.open but just with a url. In my app i've got the DOM from somewhere else so there is no need to get it twice :)
I now that you can set the page content via page.content = "<html></html>" but i'm missing the callback for loaded images, etc.
Any Ideas out there?
Have a look at casperjs' bbcshot.js code sample, it does quite exactly what you're asking for.

delay "creation" of div, not just showing of div

I may not be using the proper terminology but hopefully I get my question across properly. What I'm wondering is if it's possible to "delay" the "creation" of a specific div, rather than just delay the FadeTo or Show jquery command.
I ask because I'm using the Vimeo API which is completely mind-boggling and frustrating (at least for me - it's a source of endless shame and I wallow in self-pity when attempting any such Vimeo API coding). What I'm trying to do is just delay the autoplay of the iframe code for an embedded Vimeo video. The problem is that I have the div containing the vimeo iframe set to hide for a good three seconds after the page loads before it fades in, but since it's just hidden the video starts playing anyway before the visitor can actually see it. I'm just using &autoplay=1 for the vimeo embed...
So, I suppose the only other solution besides getting this confusing Vimeo API to try to delay the video that way is to be able to just use a jQuery command to delay the vimeo iframe from even loading/being created on the page, until the container div fades in.
If this is possible I will bless my lucky charms. And double points if someone answers in the next few hours! Thanks so much!!!
I just editted my answer and applied it to fit your code you provided:
So what I did here is: 1) load jquery into your page2)when jquery sees your div with id="div" as 'ready', it will fire an alert that says loaded (you can remove this it was just for testing purposes), and then delay the src from loading in your iframe for 2 seconds (2000 miliseconds)
3) So you can change the 2000 to whatever time you want, and make sure the "player_1" matches your iframes id
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.7.2/jquery.min.js"></script>
<script>
$(document.getElementById('div')).ready(function()
{
alert('loaded');
setTimeout('document.getElementById("player_1").src="http://www.youtube.com/v/82CYNj7noic?autoplay=1"', 2000);
});
</script>
<div id="div" class="div">
<iframe class="iframe" id="player_1" > </iframe>
</div>
​
​
Does this work for you?? I hope I've helped!!

Resources