A website I am working on has to use the Facebook Connect "Old JavaScript Client Library" API (the new "JavaScript SDK" has not yet implemented all the features we need).
Additionally, we need to have support for multiple languages. I know that when using the new API, you may specify a locale when you initialize FB Connect (like so):
<div id="fb-root"></div>
<script type="text/javascript">
window.fbAsyncInit = function() {
FB.init({
appId: 'XXXXXXXX',
status: true,
cookie: true,
xfbml: true
});
};
(function() {
var e = document.createElement('script'); e.async = true;
e.src = document.location.protocol +
'//connect.facebook.net/fr_CA/all.js';
document.getElementById('fb-root').appendChild(e);
}());
</script>
BUT, since I have to use the old API, how can I set the locale when I am initializing like so:
<script type="text/javascript" src="http://static.ak.connect.facebook.com/js/api_lib/v0.4/FeatureLoader.js.php"></script>
<script type="text/javascript">
FB_RequireFeatures(["XFBML"], function(){
FB.Facebook.init("XXXXXXXXX", "/xd_receiver.html");
})
</script>
I'm not sure that it is relevant to the issue at hand, but should it matter, the bit of FBML I am rendering is the fb:comments tag.