sjdskl/swxbot 问题修复 & 功能扩展

解决BUG、新增功能、兼容多环境部署,快速响应你的开发需求

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

sjdskl/swxbot

Composer 安装命令:

composer require sjdskl/swxbot

包简介

weixin web login and tasks

README 文档

README

Guzzle is php weixin client that can login and send message and do something you want

  • Sample login weixin
#create and add logininfo
$swxbot = new swxbot\Core\WeChat(swxbot\Library\Login\Logininfo::getInstance());
#show qrcode
$swxbot->showQrCode();
#login
$swxbot->login();
  • multi process
#create process
$process = new swxbot\Library\Progress\ProgressPcntl();
#run background
$process->runBackground();
#create new process to run your code
$process->run(function () use ($swxbot) {
    echo "i am sjdskl1\n";
}, 'swxbot-process1');
$process->run(function () use ($swxbot) {
    echo "i am sjdskl2\n";
}, 'swxbot-process2');
  • tasks
#use process run tasks, your task need extends abstractTasks
$process->runTask(new \Library\Tasks\TzgLog($swxbot), 
array(
    'php-act-root-dir' => '/opt/web-data/php-act',
    'sleep_time' => 5,
    'monitor_files' => array('sql_error')
), 
'swxbot-log-notify');
  • listen message helper
#you can user helper to handle the message
$helper = new swxbot\Library\Helper\ListenMessageHelper();
$helper->add('test', new swxbot\Library\ListenMessage\TestListenMessage());
$helper->add('test2', new swxbot\Library\ListenMessage\TestListenMessage2());
$swxbot->setListenHelper($helper);
$process->runBackground();
$process->run(function () use ($swxbot) {
    $swxbot->listenMessage();
}, 'swxbot-listen-message');

统计信息

  • 总下载量: 50
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 2
  • 点击次数: 1
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 2
  • Watchers: 1
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: Unknown
  • 更新时间: 2017-04-10

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固