Open all generated links in an iframe to open in a new window or tab - iframe

So I've been given an embed code to display a leader board on my website but if I click on any of the links in the iframe I get a connection refused.
So I need a way that when you click on any of the links they open in a new window or tab.
I've looked everywhere and can't see to find a solution as I don't have control of the domain the links are generated from.
The code I was given was this.
<iframe src="https://theurl" width="100%" height="500" frameborder="0" scrolling="auto" allowtransparency="true"></iframe>
Tried looking for a solution but they all seem to be with links that I make.
Please note have very little coding understanding and just starting out.

Related

Youtube iframe api Blocked loading mixed active content

On our website which is built in Kentico we have embedded a youtube video, as follows:
<div class="youtube">
<iframe width="100%" height="100%" src="https://www.youtube.com/embed/<%# Eval("YouTubeId") %>?autoplay=0&autohide=1&controls=1&loop=0&playlist&rel=0&fs=1&wmode=transparent&showinfo=0&modestbranding=1&iv_load_policy=1&start=0&theme=dark&color=red&enablejsapi=1&" frameborder="0" allowfullscreen></iframe>
</div>
The above iframe has a thumbnail associated with it, which looks like this
<div class="poster"><span></span><%# IfImage("Thumbnail",GetBrickImage(Eval("Thumbnail"), "featurevideo", Eval("Title")), "") %></div>
and sits just under the closing div of class youtube.
Now my issue is when the users come to the site and presses play on the thumbnail the video doesn't play straight away instead the thumbnail disappears and the default youtube play button appears making the user press play again, when I use the developer tool bar and press play for the first time I get the error
Blocked loading mixed active content "http://www.youtube.com/iframe_api"
I cannot for the life of my figure out what is going wrong, We have recently installed a SSL certificate on the server this site currently sits on and since then its been causing this issue. From what I have read and see people were suggesting to drop the www. so it would be https://youtube.com.... again this didn't help me. I then went and tested this on IE10/Chrome and the issue is still happening. Can anyone suggest anything for this?
It is a limitation of the CKEditor. It has been resolved in version 8.2.1.
http://devnet.kentico.com/questions/kentico-v8-ckeditor-youtube-embeds-https

Cannot see website using html iframeg

I am having a website.
I want it to be displayed as an Iframe on my partner site.
<iframe src="http://www.mywebsite.com"></iframe>
However, when he try to see it, nothing is showing up, blank page, but if he change the same iframe source to youtube for example, he got the videos.
Very strange, any idea where the problem is coming from ?
Cheers

Like box - opening in new window

Trying to implement a FB like box iframe in my website gulbrand.net.
Following code is used:
<iframe src="http://www.facebook.com/plugins/likebox.php?href=
http%3A%2F%2Fwww.facebook.com%2Fgulbrandnet&width=500&height=1000&
colorscheme=light&show_faces=false&border_color&stream=true&
header=true" scrolling="no" frameborder="0" style="border:none; overflow:hidden;
width:500px; height:1000px;" allowTransparency="true"></iframe>
It appears allright on my testsite. A link to the gulbrand.net FB page with a like button. And posts from the FB page.
But: When pressing the like button a new browser window (IE) for login in to FB is opened. I am already logged into FB and would expect that I liked the FB page automatically (and maybe that the count of likes would increase with 1). When I put in my password in the login panel just a new blank page is opened. And I have not "liked" the FB page.
Anything I do wrong? Solutions?
What is most likely happening because you are using IE is that it is creating a new process for every tab you are making. It also blocks cross domain cookies by default. Problems with losing session cookies in popups have also been noted. This is mostly specific to IE8 from what I have heard, but you haven't mentioned what version. You can read more about this here: http://blogs.msdn.com/b/askie/archive/2009/03/09/opening-a-new-tab-may-launch-a-new-process-with-internet-explorer-8-0.aspx It is an ongoing issue.
What I recommend is you use a chrome frame: http://www.google.com/chromeframe/?prefersystemlevel=true to redirect users to use a better browser like chrome. It is easy to integrate into any website. Learn more at the link above. Let us know if this is happening to you only on IE8 or chrome or other browsers too.

Is this possible to render youtube link with iframe on Twitter?

Well, try this on fiddle :
<iframe allowtransparency="true" frameborder="0" scrolling="no" src="//platform.twitter.com/widgets/tweet_button.html?url= http://www.youtube.com/watch?v=vabnZ9-ex7o" style="width:100px; height:32px;"></iframe>
when you OPEN the page you will see "0" on twitter. But, if you "run it" (on fiddle) it will show "24". Why? And How can I fix it?
To me is seems like a connection issue. As you click the fiddle the first time, you get the same behavior as you experience on Twitter. However, when you click run to update, it works the way it should.
... and what exactly do you mean by OPEN?
edit:
The IFrame uses the referral url. If you take a look at JSFiddle, the counter links to how many have shared the page where the IFrame is present. Instead of the YouTube url you provide using the src attribute.
This makes sense when you think of the actual use of the Tweet-button.
But it is still a bit odd, that the count it shows on JSFiddle refers to the YouTube link you provided and not JSFiddle.
However, if you do remove the YouTube link you can in fact see the counter change to how many who's shared JSFiddle's display page.
This confirms, that providing a external source to the IFrame is not a decent way of making this work.
If this is necessary, the button must be created using the anchor element instead of using IFrame.
See this https://dev.twitter.com/docs/tweet-button

How to make links inside an IFRAME to open outside this Iframe?

I have created a widget kind of. In reality I put the information in a php file and then I provided the Iframe code for this file to my members.
Considering site A is member's site and site B is my site.
Site A shows the IFRAME:
<iframe src="http://siteB.com/try.php" height="240px" width="286px"></iframe>
When this IFRAME is clicked, it opens a new pop window, because of this code:
<?php echo $status_img; ?>
So far so good.
Now the problem is this pop up window also has a link. How can I make this link open outside this IFRAME, to be more specific, to take them to Site B , my site . At the moment this link opens inside the iframe and it can't be used this way.
This last link is:
<a onclick="return targetopener(this,true)" target="_top" href="http://siteB.com/services.php">
It works perfectly in my site but not in an Iframe. I know I complicated myself a little with this iframe but I adapted a solution to my poor knowledge. I'm opened to new solutions though, if this link can't be opened outside the Iframe. Thank you in advance!
Try changing target to _parent if you want the link to open in the previous window (it's parent window). So if site B opens up a pop-up with site A inside that then must refer them back to Site B then this should open the link in the window that spawned the popup.
But if you want it to open a new window that leads to your website then of course use _blank.
You can use this base tag. Place the tag in the iframe. Should solve your issue.

Resources