I'm proposing here that we use a simple direct URL to the _files.xml and _meta.xml rather than the current scraping of the screen looking for the "All Files" HTML link. Although without an API neither is perfect I feel like this way is simpler and perhaps "slightly" less likely to change.
If you have a video (or audio for that matter) with video code (title) of "myvideo", then your normal download URL for files is
http://www.archive.org/download/myvideo/somefile
I also noticed that the myvideo_files.xml and myvideo_meta.xml can be found at the following URLS
http://www.archive.org/download/myvideo/myvideo_files.xml
http://www.archive.org/download/myvideo/myvideo_meta.xml
So as long as you have the video code it is a trivial matter to construct the above URLs. That is what the attached patch does.
Now I will mention that when you go to the above links archive.org does a redirect. However, the drupal_http_request (called from emfield_request_xml is designed to handle simple redirects). In my (admittedly brief) testing it appears to work fine.
| Comment | File | Size | Author |
|---|---|---|---|
| emfield-xmlurls.patch | 1.91 KB | winston |
Comments
Comment #1
winston commentedComment #2
winston commentedHmm, this actually depends on...
http://drupal.org/node/165731
Comment #3
alex ua commentedI'm moving this over to the Media:Archive queue.
Comment #4
winston commentedHmm, had tried this and had some problems. Opening it to try again.
Comment #5
winston commentedComment #6
winston commentedFixed in http://drupal.org/cvs?commit=457154