开发者

Facebook and iFrames

开发者 https://www.devze.com 2023-01-29 06:35 出处:网络
Hey people, why won\'t this code work? The Facebook API is so bad it\'s annoying... [edit] I felt that wasn\'t heavy handed enough, it\'s not only annoying, it\'s downright backwards and the documenta

Hey people, why won't this code work? The Facebook API is so bad it's annoying...

[edit] I felt that wasn't heavy handed enough, it's not only annoying, it's downright backwards and the documentation is dire at best....[/rant]

<a href="#" id="click" onclick="outside_location.setInnerFBML(link_1);">Go go go</a><br />

<div id="outside_location"></div>
<fb:js-string var="link_1">
<fb:iframe height="500" allowTransparency="true" frameborder="0" scrolling="no" style="width:100%; border:none" src="http://www.project-vanquish.co.cc/fb/index.php"></fb:iframe>
</fb:js-string>

<script type="text/javascript" charset="utf-8">
    var outside_location = document.getElementById('outside_location'); 
</script>

To elaborate, let's backtrack... The Facebook API states that I can have a fb:iframe oon a st开发者_运维技巧atic FBML page, so... if I only have the following, it should work:

<fb:iframe height="500" allowTransparency="true" frameborder="0" scrolling="no" style="width:100%; border:none" src="http://www.project-vanquish.co.cc/fb/index.php"></fb:iframe>

Alas nothing happens, any idea why?


Could you link to it?

Is it an installable application in a page? If that's the case, you can't embed an iframe without the user interacting with your application first.

I think that's the case, and yes, the Facebook documentation sucks and that's a compliment.

0

精彩评论

暂无评论...
验证码 换一张
取 消