Download the PHP package zlt/php-google-drive without Composer
On this page you can find all versions of the php package zlt/php-google-drive. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download zlt/php-google-drive
More information about zlt/php-google-drive
Files in zlt/php-google-drive
Package php-google-drive
Short Description Easy-To-Use PHP Library For Google Drive
License MIT
Informations about the package php-google-drive
Easy-To-Use PHP Library For Google Drive
-
Installation
-
Setup
If you don't know how to find the credentials i.e, clientId, clientSecret, refreshToken, read here.
-
Usage
-
Creating Content
Use
put
method which accepts three parameters:content
- contents to be storedfileName
- filename of content to be storeddir
- If not specified, file will be stored under root. Otherwise, file will be stored under specifed dir.
-
Getting File
Use
get
method which accepts two parameters and returnGoogle\Drive\DriveFile
orGuzzleHttp\Psr7\Response
fileName
- filename of content to be storedparams
- If not specified, empty array is passed.
-
Getting File Content
Use
getContent
method which returnGuzzleHttp\Psr7\Response
.fileName
- filename of content to be stored
-
Creating Dir
Use
makeDirectory
which accepts two parameters:folderName
- folderNamedir
- If not specified, folder will be created under root. Otherwise, folder will be created under specifed dir.
-
Copy File
Use
copy
which accepts three parameters:fromId
- fileIdfileName
- fileNamedir
- If not specified, folder will be created under root. Otherwise, folder will be created under specifed dir.
-
List Contents
Use
listContents
method which accepts two parameters:path
which is either pathId, fileName, folderName ,andrecursive
which decide to show children contents. -
List Directories
Use
directories
method which accepts two parameters:path
which is either pathId, fileName, folderName -
List Files
Use
files
method which accepts two parameters:path
which is either pathId, fileName, folderName -
Delete File or Folder
Delete file