Col*_*tor 7 internet-explorer facebook xfbml internet-explorer-8
我最近使用XFBML实现了Facebook登录按钮和Facebook"赞"按钮.您可以在http://colnect.com上看到该网站
一切都适用于FireFox,Chrome,Opera和Safari.
但是,IE既不显示"登录"或"喜欢"按钮,也没有错误消息可用.
有任何想法吗?
似乎我会成为那种回答自己的人,希望能帮助别人.
要让Internet Explorer识别Facebook,您应该添加
xmlns:fb="http://www.facebook.com/2008/fbml"
Run Code Online (Sandbox Code Playgroud)
对你的html标签,对我而言
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:fb="http://www.facebook.com/2008/fbml" xml:lang="en">
Run Code Online (Sandbox Code Playgroud)
我遇到的第二个问题是IE不支持Array.indexOf()所以这就是它的方法:
if(!Array.indexOf){
Array.prototype.indexOf = function(obj){
for(var i=0; i<this.length; i++){
if(this[i]==obj){
return i;
}
}
return -1;
}
}
Run Code Online (Sandbox Code Playgroud)
希望能帮助到你.
| 归档时间: |
|
| 查看次数: |
8345 次 |
| 最近记录: |