I\'m using the Facebook JS sdk, and I have created a new App today. Everything is configured properly. Using init function like:
window.fbAsyncInit = functio         
        
In my case it was an api version problem, as suggested by the error message.
Let the version loaded in the FB script tag match the one in your FB initialization script, by specifing the same when loading the sdk (in the hash), for instance for version 4.0:
and in your script like:
window.fbAsyncInit = function() {
    FB.init({
        appId: XXX,
        autoLogAppEvents: true,
        xfbml: true,
        version: 'v4.0' //<------------- same version
    });
};