fixed unfollow button

v1.18.x
Baris Usakli 12 years ago
parent d1041bedf4
commit 09c80b8289

@ -59,7 +59,7 @@
</div>
</div>
<div id="user-actions" class="container">
<a id="add-friend-btn" href="#" class="btn">Add Friend</a>
<a id="add-friend-btn" href="#" class="btn">Follow</a>
</div>
<br/>
<div id="user-action-alert" class="alert alert-success hide"></div>
@ -104,16 +104,14 @@ var theirid = '{theirid}';
addFriendBtn.on('click', function() {
$.post('/users/addfriend', {uid: theirid},
function(data) {
addFriendBtn.remove();
$('#user-action-alert').html('Friend Added!').show();
}
);
return false;
});
});
}());
</script>

@ -32,7 +32,7 @@
<span class='postcount'>{friends.postcount}</span>
<i class='icon-pencil'></i>
</div>
<a id="remove-friend-btn" href="#" class="btn remove-friend-btn" friendid="{friends.uid}">Unfriend</a>
<a id="remove-friend-btn" href="#" class="btn remove-friend-btn" friendid="{friends.uid}">Unfollow</a>
</div>
<!-- END friends -->
@ -72,7 +72,7 @@ var friendCount = '{friendCount}';
$.post('/users/removefriend', {uid: friendid},
function(data) {
button.parent().remove();
removeBtn.parent().remove();
}
);
return false;

Loading…
Cancel
Save