[ Index ] |
PHP Cross Reference of Unnamed Project |
[Source view] [Print] [Project Stats]
A helper class to access dropbox resources
Author: | Dongsheng Cai <dongsheng@moodle.com> |
Copyright: | 2012 Marina Glancy |
Copyright: | 2010 Dongsheng Cai |
License: | http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later |
File Size: | 168 lines (6 kb) |
Included or required: | 1 time |
Referenced: | 0 times |
Includes or requires: | 0 files |
dropbox:: (7 methods):
__construct()
get_listing()
prepare_filepath()
get_thumbnail()
get_file()
get_file_share_link()
set_mode()
__construct($args) X-Ref |
Constructor for dropbox class param: array $args |
get_listing($path='/', $token='', $secret='') X-Ref |
Get file listing from dropbox param: string $path param: string $token param: string $secret return: array |
prepare_filepath($filepath) X-Ref |
Prepares the filename to pass to Dropbox API as part of URL param: string $filepath return: string |
get_thumbnail($filepath, $saveas, $timeout = 0) X-Ref |
Retrieves the default (64x64) thumbnail for dropbox file param: string $filepath local path in Dropbox param: string $saveas path to file to save the result param: int $timeout request timeout in seconds, 0 means no timeout return: array with attributes 'path' and 'url' |
get_file($filepath, $saveas, $timeout = 0) X-Ref |
Downloads a file from Dropbox and saves it locally param: string $filepath local path in Dropbox param: string $saveas path to file to save the result param: int $timeout request timeout in seconds, 0 means no timeout return: array with attributes 'path' and 'url' |
get_file_share_link($filepath, $timeout = 0) X-Ref |
Returns direct link to Dropbox file param: string $filepath local path in Dropbox param: int $timeout request timeout in seconds, 0 means no timeout return: string|null information object or null if request failed with an error |
set_mode($mode) X-Ref |
Sets Dropbox API mode (dropbox or sandbox, default dropbox) param: string $mode |
Generated: Thu Aug 11 10:00:09 2016 | Cross-referenced by PHPXref 0.7.1 |