views:

204

answers:

2

I have used this same call in other IFRAME Facebook apps, but it gives me nothing at all in terms of output. I am trying it on Yii and getting nothing.

<script type="text/javascript">

  window.onload = function() {

    FB_RequireFeatures(["XFBML"], function() {

      FB.init('xxxxxx', 'xd_receiver.htm');

      FB.XFBML.Host.get_areElementsReady().waitUnitlReady(function()
        {
          document.getElementById("container").style.visibility = "visible";
        });

    });

  };

</script>

<script type="text/javascript">

function publish() {
 FB_RequireFeatures(["Connect"], function() {
   FB.init('xxxxxx', 'xd_receiver.htm');
   FB.ensureInit(function() {
     FB.Connect.streamPublish();
   });
 });
}

</script>

<fb:serverFbml style="width: 755px;">
 <script type="text/fbml">
  <fb:fbml>
   <fb:request-form
      action="http://apps.facebook.com/ixxxx"
      method="POST"
      invite="true"
      type="rrrrr"
      content="rrrrr <?php echo htmlentities("<fb:req-choice url=\"http://apps.facebook.com/XXXX\" label=\"Authorize My Application\"") ?>" > 
<fb:multi-friend-selector showborder="false" actiontext="Invite your friends to use SuperThief."> 

   </fb:request-form>
  </fb:fbml>
 </script>
</fb:serverFbml>
A: 

It might be helpful to check that you have your new Yii site setup correctly for Facebook. You might not be including the right JavaScript libraries in the layout file's , or you may have forgotten to add the right xmlns attribute to the tag. For a refresher on this stuff head over to the Facebook documentation here: http://wiki.developers.facebook.com/index.php/Connect/Setting_Up_Your_Site

thaddeusmt
A: 

I have got the same problem, I'm new to Yii but it appears it just stops reading the view after the <script> tag, I haven't found any solution yet but I'm sure it is related to the <script> tag on the body (no problems if it is inside the head tag).

Emilio Bool