kisphp/php-sftp-client 问题修复 & 功能扩展

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

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

kisphp/php-sftp-client

Composer 安装命令:

composer require kisphp/php-sftp-client

包简介

Tiny PHP SFTP client

README 文档

README

example workflow

Installation

Add in composer:

{
    "require": {
        "kisphp/php-sftp-client": "~0.1"
    }
}

Usage

Create a config class that implements ConfigInterface

<?php

use Kisphp\ConfigInterface;

class Config implements ConfigInterface
{
    public function getHost()
    {
        return '10.10.0.61';
    }
    
    public function getPort()
    {
        return 22;
    }
    
    public function getUsername()
    {
        return 'vagrant';
    }
    
    public function getPassword()
    {
        return 'vagrant';
    }
}

Instantiate SftpConnect class and pass your Config object to it

$s = new SftpConnect(new Config());

Upload a file

$s->sendFile(__DIR__ . '/source.php', 'b.php'); // will return true for success and false for failure

Download a file

$s->receiveFile('a.php', 'c.php'); // will return true for success and false for failure

统计信息

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

GitHub 信息

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

其他信息

  • 授权协议: MIT
  • 更新时间: 2016-09-23

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固