寻找和搜索我几乎不期望答复;)因为我不认为这似乎很多人都尝试过。问题相对较小,我更希望有人遇到同样的问题。所以我们会看到。像按钮阿贾克斯iframe布局从按钮计数恢复到标准
//when share is clicked remove all content in share and add in facebook's like button
$('#flb').live('click',function(){
var ID = $('#question-shell').attr('data-id');
$('#flbCont').empty().append($('<iframe />')
.attr('src', 'http://www.facebook.com/plugins/like.php?href=http%3A%2F%2Fwww.wouldyourather.eu%2F%3Fid%3D'+ ID +'&layout=button_count&show_faces=false&width=100&action=like&colorscheme=light&height=21')
.attr('scrolling', 'no')
.attr('frameborder', 'no')
.attr('style', 'border:none; overflow:hidden; width:450px; height:80px;')
.attr('allowTransparency', 'true')
);
return false;
});
这是我的代码。只需简单地删除Facebook共享占位符中的任何内容并添加新的动态内容即可。但它的jquery中的风格有标准显示,即使在html中它说它应该加载标准而不是button_count版本。
任何想法都将是布瑞尔:)
干杯家伙
欢呼的答复猪头...其漂亮知道有人在乎:) 嗯,我编辑的代码来读取这样的,但仍然没有运气,它仍然默认为标准:( $(“# flbCont').empty()。append($('') .attr('src','http://www.facebook.com/plugins/like.php?href=http%3A%2F%2Fwww .wouldyourather.eu%2F%3Fid%3D '+ ID +' &布局= button_count & show_faces =假&宽度= 100 &行动=像&色彩方案=光&高度= 21&安培”)可悲无下列工作,所以我 – 2011-01-13 12:58:27