I have a public folder in my drive. I need to be able to download the whole folder, keeping the structure intact, and download certain files. I am using the chrome.filesystem api to overwrite some user files with the ones that are downloaded. I am downloading a json from the same folder to determine which files need to be downloaded. I could list the urls to all the files in that json, but that seems inefficient and is annoying. How could the urls be determined in a better way?
Unfortunately, there is no way to download a whole folder at this moment. I have seen other solutions, for example zipping all the urls and downloading a single zip file. You can read more information on this issue: How i can get multiple files from google drive through the google drive api?
Related
Good morning, I have a problem. The service that I am using in my project will return three files in base64 (.pdf, .xml and .cdr). It works fine when I try to download the pdf and xml files, but when I try to download the .cdr files it doesn't download properly. I already search for several types of mime but it doesn't work. Do you know how I can solve it?
This is a bit of a process question and not a specific question.
I have an React/Firebase application where the user needs to be able to download multiple pdfs in a single file. The pdfs themselves are not merged together.
Downloading a single pdf from firebase storage isn't too difficult. But how do I collect those pdfs (returned as blobs) into a single folder and then ship that folder to the user as a singular download?
Is there a library for this? Am I thinking about this in the wrong way?
You will likely want a backend firebase function that can retrieve the individual pdfs, and then you can collate them into a single zip object using https://stuk.github.io/jszip/
I'm trying to download a zip file stored in an Amazon S3 bucket.
I've found the location of the file in the site's javascript but if I just stick that in the address bar i get 'access denied'.
The zip contains CAD models which are unzipped (presumably remotely) and visualized in a javascript 3D model viewer on the page when loaded.
I have to be logged-in in order to load the page, does this mean I can somehow get access to the zip file?
If it has any relevance, after the file's location URL is an AWSAccessKeyID, Signature and Expiry.
And if it wasn't already obvious, I have no coding experience but I'd really like some pointers if this is even possible.
So I've been blindly messing about and have managed to download the zip file.
I just copied and pasted the javascript code that included the file location in the console. It started with 'JSON.parse' and hey presto a downloadable link appeared! I had no idea it would be so easy.
I have the URLs of a list of images. Now on click of a link, ineed to to zip the images in all those URL's and provide it as a downloadable file. What i have currently done is,
Pass the URLs to django views
Fetch the images and store it to filesystem
Zip them and
Return a download dialog as response
Now, i am thinking of doing everything at the client side itself.I came across the JS plugin Zip.js that can zip files. My only problem is how to fetch those images from the URL's and zip them in memory using JS.Any help is appreciated.I also came across other plugins to zip files,
http://www.jquery4u.com/javascript/javascriptjquery-zipfilecompressor-plugins/#.UE8cI2AxznA
https://raw.github.com/Stuk/jszip/master/jszip.js
As #VisioN said, the zip.js plugin or any other plugins fails some browser tests, the only way to do this will be on the server side.
I found a javascript plugin that could generate zip files, its called jszip.
I tried it, but I think it could only generate the files that will be compiled in a zip file.
What I want is to be able to add existing files to the zip file that it will generate. Is it possible in JavaScript?
Scroll down to the Documentation section on the page you linked to. It describes plainly how to add files to the zip file. For binary files you'll end up using base64, it looks like. For text files you can pass them straight in as strings. Of course you'll need access to the file data in order to add it to the zip file, which is easy enough if you're, say, retrieving said data in an Ajax request, but an uphill battle if you want the user to be able to zip files from his or her local storage.