diff --git a/upload/ajax.php b/upload/ajax.php index 25e658a2..45250c9f 100644 --- a/upload/ajax.php +++ b/upload/ajax.php @@ -566,9 +566,13 @@ if(!empty($mode)) case 'add_friend': { + global $cbemail; $friend = mysql_clean($_POST['uid']); $userid = userid(); - + $username = username(); + $mailId = $cbemail->get_email_by_userid($friend); + $cbemail->friend_request_email($mailId['email'],$username); + if($userid) { $userquery->add_contact($userid,$friend);