web UI and file system access

9 views
Skip to first unread message

Marisa DeMeglio

unread,
Apr 23, 2013, 10:34:05 PM4/23/13
to daisy-pip...@googlegroups.com
I'm helping a user with some pipeline issues, and I just want to confirm a few suspicions:

* the web UI does not use the local file system in the same way that the CLI does, so you have to upload more than just the input file (i.e. the whole fileset not just ncc.html)

* if the book's folder structure is flat, you can just upload a bunch of files at once

* otherwise, you have to zip up the contents and upload the zip file

I find that on my machine, if I follow these rules, it works great! I just converted a very huge book to EPUB 3.

Thanks
Marisa

Jostein Austvik Jacobsen

unread,
Apr 24, 2013, 1:09:05 AM4/24/13
to daisy-pip...@googlegroups.com

Yes all that is true. The reason is that websites doesn't have (and can't be given) access to the file system.

--
You received this message because you are subscribed to the Google Groups "DAISY Pipeline Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to daisy-pipeline-...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


Marisa DeMeglio

unread,
Apr 25, 2013, 1:50:52 PM4/25/13
to daisy-pip...@googlegroups.com
Ok thanks for confirming. I have another question -- when you upload a zip file representing a whole book, the web UI takes a guess at which file should be sent to the script. How does it determine this? In the Daisy 2.02 to EPUB 3 script, for example, the required option is for "ncc.html" but the web UI selects a content html file instead. What guides it?

Jostein Austvik Jacobsen

unread,
Apr 25, 2013, 4:02:29 PM4/25/13
to daisy-pip...@googlegroups.com
px:media-type="application/xhtml+xml text/html" on the p:option element which is presented through the mediaType attribute in the script description in the Web API.

We don't have any way of filtering by filename, although it could be interesting to have an attribute taking a glob or a regex to match filenames.

Another solution (which I've suggested before) would be to make the script aware of the context directory without using a p:option with px:type="anyFileURI" or input ports. For instance, we could have px:type="inputDir" or something which would allow the script to find the ncc.html file by itself without needing a widget for it.


Jostein
Reply all
Reply to author
Forward
0 new messages