Skip to content
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

Hi, Marielle,is it possible for ibook html widget to open and read a local file ? #1

Open
OrNot opened this issue Dec 9, 2013 · 4 comments

Comments

@OrNot
Copy link

OrNot commented Dec 9, 2013

No description provided.

@widged
Copy link
Owner

widged commented Dec 10, 2013

A widget can access any file embedded within the widget package but it cannot access a file on your local file system. As per apple documentation "Widgets in books created with iBooks Author cannot access files in the general file system." See http://support.apple.com/kb/ht5068.

@OrNot
Copy link
Author

OrNot commented Dec 11, 2013

Marielle,
I have a XML file. Suppose I can embed it within the widget bundle, I can read it out with HTML5 file API ?

thanks a lot

@widged
Copy link
Owner

widged commented Dec 11, 2013

@OrNot The HTML5 file API is for accessing the user file system and therefore wouldn't do. You have to try with a good old "XMLHttpRequest". I haven't played with iBook widgets recently. You area likely to find more knowledgeable people on stackoverflow. For instance, how to load xml file and how to enable "Allow Network Access" (that dates from 2010, it might have changed, but this gives you an idea of what to look for).

@OrNot
Copy link
Author

OrNot commented Dec 11, 2013

Thanks a lot.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants