Reputation: 391
So I am working on a small website with some simple admin area. In the admin area it should be possible to upload/download/update files of a global directory. The problem is that my php programs don't have write permission to the server and the size limit of the database is 100mb which is not enough. Therefore I thought it would be nice to store the files in a dedicated Dropbox account or something.
My questions are:
Edit: My problem with Dropbox is that it's API uses OAuth. But since I want to connect to one global account for all users instead of each users account this seems inappropriate and I don't even know if the authentication is possible this way. All the links mentioned use this API and therefore need user authentication through a redirect.
Upvotes: 0
Views: 1437
Reputation: 7853
Yes you can use the dropbox account. Try out the PhpDropboxUploader. Its also mentioned in the dropbox Wiki
require 'DropboxUploader.php';
$uploader = new DropboxUploader('[email protected]', 'dropbox-password');
$uploader->upload('file-to-be-uploaded', 'destination-folder-in-dropbox');
Upvotes: 3
Reputation: 1769
for your first question, there is indeed a PHP SDK that is not official but still listed on dropbox site : https://www.dropbox.com/developers/reference/sdk and https://github.com/BenTheDesigner/Dropbox
btw, are you sure you can't make a directory for which PHP has write permission ?
Upvotes: 1