is_followed_by_name() публичный Метод

如果源用户或目的用户不存在,将返回http的400错误
对应API:{@link http://open.weibo.com/wiki/2/friendships/show friendships/show}
public is_followed_by_name ( mixed $target_name, mixed $source_name = NULL ) : array
$target_name mixed 目标用户的微博昵称
$source_name mixed 源用户的微博昵称,可选,默认为当前的用户
Результат array
Пример #1
0
 public function getFriendID($myUsername, $name)
 {
     $token = getWeiboToken();
     if (!$token) {
         throw new InvalidArgumentException('no token');
     }
     $c = new SaeTClientV2(WB_AKEY, WB_SKEY, $token);
     $array = $c->is_followed_by_name($myUsername, urldecode($name));
     if ($array['target']['followed_by'] or $array['target']['following']) {
         return $array['source']['id'];
     }
     return false;
 }