Facebook FXBML since yesterday no rendering (IFRAME Canvas)

since yesterday my application does not display xfbml tags (name and image). Iam using the new JavaScript SDK inside the Canvas-Iframe application.

Firebug tells me the following inside the console:

Get: http://0.channel20.facebook.com/x/3332504234/true/p_1348362044=0 

And after a while:

  XFBML tags failed to render in 30000ms. 

Does anyone have the same problems or know why this is happening?

+4
source share
2 answers

The fact that I had the same problem for a long time and is able to solve it only now.

That's all and all, you just need to wrap all the XFBML code in JS / jQuery and parse it as shown below:

  $('#like').html('<fb:like href="'+url+ '" layout="button_count" show_faces="false" width="65" action="like" font="segoe ui" colorscheme="light" />') if (typeof FB != "undefined"){ FB.XFBML.parse(document.getElementById('like')) } 

HTML code:

  <div id="like"> </div> 

You are done.

+11
source

Facebook recently posted a major update to its API, including changes to their Javascript and XFBML functions. Not sure when the old interfaces are out of date, but you may be in a crossfire if you are not using the new API.

The new API is here: http://developers.facebook.com/docs/reference/javascript/

+2
source

Source: https://habr.com/ru/post/1310195/


All Articles