我在Facebook上創建了一個請求對話框,它在Firefox和Chrome中非常好用,但在IE8中,它給了我錯誤:FB is undefined
。請在以下代碼中找到我使用的代碼。「FB is undefined」IE8的錯誤
<html xmlns=="http://www.w3.org/1999/xhtml"
xmlns:fb="https://www.facebook.com/2008/fbml">
<head>
<title>Request Tester C</title>
</head>
<body>
<div id="fb-root"></div>
<script src="http://connect.facebook.net/en_US/all.js"></script>
<p>
</p>
<script>
FB.init({
appId : 'XXXXXXXXXXXXXXXXXXXXX',
status : true,
cookie : true,
oauth: true
});
function sendRequestViaMultiFriendSelector() {
FB.ui({method: 'apprequests',
message: 'My Great Request'
}, requestCallback);
}
function requestCallback(response) {
// Handle callback here
window.location.href = "test.php";
}
sendRequestViaMultiFriendSelector();
</script>
</body>
</html>
感謝安德魯的幫助,我用上面的代碼,但我得到了以下錯誤: 錯誤:FB_RequireFeatures沒有定義 源文件:XXXXXXXXXXXXXXXX 線:23個 任何想法,請 – user1022745
你可能使用廣告攔截軟件的某種? –