-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
Unable to read renderless.html file when i change the url to my book #1369
Comments
As shown in the error message in the screenshot, you cant access "file://xxx" with XMLHTTPRequest. maybe you can serve your demo with local server and access the files via the HTTP or HTTPS protocol. |
thanks for the reply, but unfortunately your solution didn't work |
I was using renderless.html as an example to get all the data in sections so that I can apply turn.js library on it. The problem i am facing regarding opening of the book is that when i use the url as specified in example, (https://s3.amazonaws.com/epubjs/books/moby-dick/OPS/package.opf), i get all the section data ,but when i changed it into my own url, it throws an error on book.spine.get(item) function. It shows CORS error, although i already have set the CORS Origin on my digital ocean , I also tried to set {contained:true} in my book constructor, but no result.
![Screenshot from 2024-01-14 19-59-18](https://private-user-images.githubusercontent.com/122437993/296561366-0a5e8f78-804b-489a-87fd-e39c651d8376.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MTg5NjU4MTEsIm5iZiI6MTcxODk2NTUxMSwicGF0aCI6Ii8xMjI0Mzc5OTMvMjk2NTYxMzY2LTBhNWU4Zjc4LTgwNGItNDg5YS04N2ZkLWUzOWM2NTFkODM3Ni5wbmc_WC1BbXotQWxnb3JpdGhtPUFXUzQtSE1BQy1TSEEyNTYmWC1BbXotQ3JlZGVudGlhbD1BS0lBVkNPRFlMU0E1M1BRSzRaQSUyRjIwMjQwNjIxJTJGdXMtZWFzdC0xJTJGczMlMkZhd3M0X3JlcXVlc3QmWC1BbXotRGF0ZT0yMDI0MDYyMVQxMDI1MTFaJlgtQW16LUV4cGlyZXM9MzAwJlgtQW16LVNpZ25hdHVyZT1iNWI3NWU0NGQ4NGU4MTY5ZGVlZWUwMzljZGY3ZWViOTgzY2MzNjdmNzFlOGU4OTE1NDNjM2UyMzFhZDNiZDhiJlgtQW16LVNpZ25lZEhlYWRlcnM9aG9zdCZhY3Rvcl9pZD0wJmtleV9pZD0wJnJlcG9faWQ9MCJ9.73_1kAFwfDXcpcq1vVuxjAnaskEnZ2N0NUMLZ2WuR5Q)
If it's really a cors error why am I unable to open it using file input too. Keep in mind, I am able a file i downloaded from google, but unable to open the one I built myself
The text was updated successfully, but these errors were encountered: