bear8421/spreadsheets-basic

轻量、简单且独立的Google Spreadsheets Basic连接器

v2.0.1 2024-09-21 20:28 UTC

This package is auto-updated.

Last update: 2024-09-21 20:46:24 UTC


README

Latest Stable Version Total Downloads Daily Downloads Monthly Downloads License PHP Version Require

1个小型库,支持将数据推送到Google Spreadsheets,并通过Google Sheet API进行数据处理。

注意

此库仅适用于小型项目,处理中、小规模1-2个sheet文件

如需更多功能,请在Google Cloud Platform上使用Google Sheet API - 请参阅以下文档:https://developers.google.com/sheets/api

版本

根据您使用的PHP版本,此库支持两个并行版本,以便您选择最适合和最优化版本

  • v1.x 支持所有PHP版本 >=5.4
  • v2.x 支持所有PHP版本 >=7.0

安装库

此库通过Composer安装

composer require bear8421/spreadsheets-basic
<?php
require_once __DIR__.'/vendor/autoload.php';
use nguyenanhung\Google\Basic\Spreadsheets\GoogleSpreadsheets;

$scriptId = '1234';
$contentData = [
    'Column1_1' => 1,
    'Column1_2' => 2,
];
$spreadsheets = new GoogleSpreadsheets();
$spreadsheets->setScriptId('1234')
->setContentData($contentData)
->push();

联系 & 支持

来自越南的爱与祝福 <3