simkeu/simkeu-gcp-repository 问题修复 & 功能扩展

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

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

simkeu/simkeu-gcp-repository

最新稳定版本:v1.0.0

Composer 安装命令:

composer require simkeu/simkeu-gcp-repository

包简介

Sim Keuangan Upload Blob to Google Cloud Storage.

README 文档

README

Library for connecting to blob repo

Requirements

  1. PHP 5.4 ++
  2. guzzle

example is in test-upload.php

Instalation

run composer require simkeu/simkeu-gcp-repository

Usage

Instalation
<?php

require_once 'vendor/autoload.php';
use Simkeu\GoogleCloudStorageRepository\GoogleCloudStorageRepository;

// Create a new StorageClient
$pathclientSecret = './myits-finance-690fb7a37295.json';
$storage = new GoogleCloudStorageRepository('simkeu', $pathclientSecret);

Store File 
$respon = $storage->uploadFile($_FILES['fileToUpload'], 'temp');

Update File 
$respon = $storage->updateFile($file_id, $_FILES['fileToUpload'], 'temp');

Delete File
$file = $storage->hapusFile($file_id);

Get File
$file  = $storage->getFile($file_id); //return base64 file

Get Url File
$file  = $storage->generateSignedUrl($file_id, 300); //return url file
Methods

uploadFile()
updateFile()
hapusFile()
getFile()
generateSignedUrl()

统计信息

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

GitHub 信息

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

其他信息

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