当前位置: 首页>>代码示例>>PHP>>正文


PHP SaeTClientV2::follow_by_id方法代码示例

本文整理汇总了PHP中SaeTClientV2::follow_by_id方法的典型用法代码示例。如果您正苦于以下问题:PHP SaeTClientV2::follow_by_id方法的具体用法?PHP SaeTClientV2::follow_by_id怎么用?PHP SaeTClientV2::follow_by_id使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在SaeTClientV2的用法示例。


在下文中一共展示了SaeTClientV2::follow_by_id方法的7个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: follow_office

 public function follow_office()
 {
     if (!defined('WB_OFFICE_UID') || !is_int(WB_OFFICE_UID)) {
         return;
     }
     $c = new SaeTClientV2(WB_AKEY, WB_SKEY, $_SESSION['sina']['token']['access_token']);
     return $c->follow_by_id(WB_OFFICE_UID);
 }
开发者ID:yunsite,项目名称:tp-coupon,代码行数:8,代码来源:sina.class.php

示例2: follow

 /**
  * 关注
  */
 public function follow($bind_user, $uid)
 {
     $info = unserialize($bind_user['info']);
     $client = new SaeTClientV2($this->setting['app_key'], $this->setting['app_secret'], $info['access_token']);
     try {
         return $client->follow_by_id($uid);
     } catch (Exception $e) {
     }
 }
开发者ID:kid2682,项目名称:SMZDM,代码行数:12,代码来源:sina.php

示例3: exit

 function send_action()
 {
     if (@$_SESSION['islogined'] <= 0 || empty($_SESSION['share_id'])) {
         exit('非法访问!');
     }
     $token = ck::get('token');
     $c = new SaeTClientV2(Sconfig::$weibo['APPKEY'], Sconfig::$weibo['APPSECRET'], $token['access_token']);
     $content = @$_POST['textarea'];
     $follow360 = @$_POST['follow360'];
     echo json_encode(array('status' => 'success'));
     fastcgi_finish_request();
     if ($follow360 == 'on') {
         //TODO: 调用关注极速360官方微博
         $r = $c->follow_by_id('1808070557');
     }
     $shareContent = strip_tags(trim($content));
     $ext_info = gClass('ExtStorage')->find_one($_SESSION['share_id']);
     $detailpicArr = json_decode($ext_info['descpic'], true);
     $ext_info['detailpic'] = $detailpicArr[0];
     $r = $c->upload($shareContent, $ext_info['detailpic']);
     $r = $c->follow_by_id('1230315942');
 }
开发者ID:z445056647,项目名称:phx-svns,代码行数:22,代码来源:webstore.php

示例4: followCoke

 public function followCoke()
 {
     $c = new SaeTClientV2(WB_AKEY, WB_SKEY, getWeiboToken());
     $answer = $c->follow_by_id(FOLLOWID);
 }
开发者ID:innomative,项目名称:16degrees,代码行数:5,代码来源:WeiboUser.php

示例5: weibo_userinfo

 public function weibo_userinfo($access_token, $follow = FALSE, $appid = 0)
 {
     require_once Kohana::find_file('vendor', 'weibo/saetv2.ex.class');
     $site_setting = $this->weibo_settings($appid);
     $c = new SaeTClientV2($site_setting['key'], $site_setting['secret'], $access_token);
     $data = array();
     if ($c) {
         $uid_get = $c->get_uid();
         $uid = $uid_get['uid'];
         $user_info = $c->show_user_by_id($uid);
         //根据ID获取用户等基本信息
         //关注官方微博
         if ($follow) {
             $c->follow_by_id($site_setting['uid']);
         }
         $data['uid'] = $uid;
         $data['name'] = $user_info['screen_name'];
         $data['avatar'] = $user_info['avatar_large'];
     }
     return $data;
 }
开发者ID:momoim,项目名称:momo-api,代码行数:21,代码来源:bind.php

示例6: friends_add

 public function friends_add($uid)
 {
     //return $uid;
     $c = new SaeTClientV2(WB_AKEY, WB_SKEY, $_SESSION['token']['access_token']);
     $ret = $c->follow_by_id((int) $uid);
     //return $ret['error_code'];
     return isset($ret['error_code']) && $ret['error_code'] > 0 && $ret['error_code'] != 20506 ? false : true;
 }
开发者ID:Capitalwang,项目名称:shehuahk,代码行数:8,代码来源:Sina_oauth.php

示例7: using

     $to_name = '任务列表';
     delay_jump(3, $msg, $to_url, $to_name);
 }
 // 已经更新了task中的数据,现在做任务
 // 先获取任务信息
 $sql = "select sina_uid, base_price, screen_name from task join task_info_sina_follow using(task_id) where task_id = {$task_id}";
 $sql_res = $dbo->getRow($sql);
 if (!$sql_res) {
     echo '读数据库出错,FILE: ' . __FILE__ . '; LINE: ' . __LINE__ . ';SQL: ' . $sql;
     $dbo->close();
     exit;
 }
 $sina_uid = $sql_res['sina_uid'];
 $base_price = $sql_res['base_price'];
 $task_owner_name = $sql_res['screen_name'];
 $task_res = $c->follow_by_id($sina_uid);
 //	if_weiboapi_fail($task_res, __FILE__, __LINE__);
 //  此处不应使用if_weiboapi_fail(),因为它对调用失败的处理只是简单的输出提示,不满足此处处理的需要。
 if (isset($task_res['error_code'])) {
     // 没做成功,回滚task表中finish_amount数据
     $sql = "update task set finish_amount = finish_amount - 1 where task_id = {$task_id} limit 1";
     $dbo->exeUpdate($sql);
     $dbo->close();
     switch ($task['error_code']) {
         case '20506':
             // 用户之前已经关注过该用户/任务不成功,将该任务用户加入当前用户已关注列表
             $msg = "该用户已经在您的关注列表中了,如果他继续出现在您的任务列表中,请手动屏蔽。";
             $to_name = '任务列表';
             $to_url = $siteRoot . 'task.php';
             break;
         case '21327':
开发者ID:mafergomez70,项目名称:micro-power,代码行数:31,代码来源:follow.php


注:本文中的SaeTClientV2::follow_by_id方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。