0
我要禁止第二次点击Google +1按钮。如何禁止第二次点击Google +1按钮
<g:plusone callback='click_callback' href="myurl.com"></g:plusone>
我click_callback
功能是:
function click_callback(b) {
if(b.state == "on") {
$.ajax({
type: "POST",
url: "gp1process.php",
data: "id=" + id,
cache: false,
success: function(a) {
$("#Hint").html(a);
remove(id);
click_refresh()
}
})
}
我可以使用jQuery的one()
方法?
学习的一个好方法是测试它是否工作 – cnorthfield
'的jQuery( 'click_callback。 ')一个(' 点击',功能(E){click_callback(E);} );' –
你想防止双击或多点击? – happymacarts