After a lot googling i acheived to send a request to add as friend, say user a sends a friend request to user b and user b logs in he will see the request from user a ... say only his name is displayed when the user clicks on that name a dialog box is opened which will ask the user whether to accpet or reject that request, the problem i am facing right now is i am not able to find how can i update the friends table status column from pending to accepted i.e when the alert message Friend request accepted is displayed the status column of friends table should be updated from pending to accepted and if rejected it should update the status column as rejected
please guide me through this
<script>
$(function(){
$("#shortthemes a").click(function(e){
e.preventDefault();
$("link#theme").attr('href',$(this).attr('href'));
$("#shortthemes a").removeClass('selected');
$(this).addClass('selected');
});
});
function tstconfirm(){
smoke.confirm('Confirm as Friend !',function(e){
if (e){
alert('Friend Request Accepted');
}else{
alert('Friend Request Rejected');
}
});
}
</script>