Opened 10 years ago

Closed 10 years ago

#193 closed enhancement (fixed)

need a function to add snapshots from folders

Reported by: simon Owned by: dstillman
Priority: major Milestone: 1.0 Beta 1
Component: data layer Version: 1.0
Keywords: Cc:

Description

when i export, i copy the folders containing webpage snapshots directly out of the storage directory. i then have no easy way of importing them in again. i could use Scholar.Attachments.importFromURL(), but since this function must first load the page into a hidden browser, and since it must operate asynchronously, it's far from ideal.

Change History (2)

comment:1 Changed 10 years ago by simon

(In [502]) addresses #103, figure out how to store captured pages in native export format

import/export of file data should work for all file types _except_ snapshots (in this situation, export is working, but import is not yet complete; see #193)
also, fixes a potential security issue that could have allowed malicious web translators to post local data to remote sites (although, given we maintain the central repository and there's no easy way to install a translator, the risk would have been minimal to begin with).

comment:2 Changed 10 years ago by dstillman

  • Resolution set to fixed
  • Status changed from new to closed

(In [510]) Closes #193, need a function to add snapshots from folders

Scholar.Attachments.importSnapshotFromFile(file, url, title, mimeType, charset, sourceItemID)

file is primary file within directory -- file.parent is copied into the storage directory
url is the original URL associated with the snapshot

Note: See TracTickets for help on using tickets.