How to get the file URL uploaded in google drive SDK using php -
i using google drive sdk upload files php. want link string can store in database. don't have idea on how it.. code in creating file in google drive using php.
$file = new google_drivefile(); $file->settitle( 'new_pdf' ); $file->setmimetype( 'application/pdf' ); $createdfile = $service->files->insert( $file, array( 'data' => $stringcontent, ));
you want 1 of properties of $createdfile.
the list of properties @ https://developers.google.com/drive/v2/reference/files
you want webcontentlink
, depends on how intend use url.
Comments
Post a Comment