-
Notifications
You must be signed in to change notification settings - Fork 32
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Local path for file imports #26
Comments
Were you thinking that the base path be a setting for the entire import, or on a per column basis? Would it check to see if the file is a valid URL, and if not, then use the base file path setting? |
I'd be a bit leery about this, given the security considerations: you could tailor a base path and your CSV to pull in any file on the server that the webserver can access. I've thought about this before, but more as an integration with Dropbox: let users specify a particular column refers to files in the dropbox dir. There'd still need to be some checking on the filenames to make sure they're not trying to traverse the directory structure and break out of the dropbox (things like |
Was thinking for the entire import, but if there are be reasons to consider it on a per-column basis, would like to hear them.
Hadn't considered this, but seems like it'd be a good idea!
Excellent point that I hadn't considered!
Yeah, this seems more like it. That you'd have to either have Dropbox installed, or maybe add a directory to CsvImport that it could use. Agreed about checking the file paths, and prohibit breaking out of a specified directory. |
@clioweb @zerocrates Do you want to use the Dropbox plugin or should we add a directory to the CsvImport plugin? What do yal think? |
A feature idea I'd like to work on is adding support for local paths for files. Instead of relying on a full HTTP address being in the CSV file, allow people to upload the files to a server somewhere, and let them specify a path as the base bath for import along with the other settings for that CSV file.
This is usually the most problematic thing I encounter helping folks import their data from a CSV file, is that they usually only have the filenames, and not a full path. I've just been doing file and replace in the files column of the CSV file, which works fine, but I think being able to specify a base path for files would be useful.
Would like to talk this out more, since I'm sure I'm not aware of all the things such a change would affect.
The text was updated successfully, but these errors were encountered: