Alex Rivera | Logout

Error: FB.login() called before calling FB.init()

Asked 2011-02-06T01:42:19.487
21

I use this Facebook Login Button code:

<div id="fb-root"></div>
<script src="http://connect.facebook.net/en_US/all.js"></script>
<script>
  FB.init({
    appId  : 'myActualId',
    status : true, // check login status
    cookie : true, // enable cookies to allow the server to access the session
    xfbml  : true  // parse XFBML
  });
</script>
<fb:login-button show-faces="false" width="200" max-rows="1"></fb:login-button>

But the debug console gives me this error: FB.login() called before calling FB.init().

I made a test page so my error can be seen: http://www.comehike.com/test_fb_connect.php

I have no idea what I am doing wrong. Any help would be much appreciated!

Thanks, Alex

Edit
Report

1 Answer

1

Seeing as no one on the interwebs was able to answer my question, I wiped out the old Facebook app entirely (on my developers.facebook.com account) and just made a new app from scratch and made a totally new one.

After that, the basic code did the job

answered 2011-02-06T16:56:04.373

Your Answer