|
|
#1 |
|
Junior Member
![]() Posts: 8
Karma: 10
Join Date: Nov 2017
Device: Kindle PaperWhite 3 (2015) WiFi
|
How to access the elements in "read-book-iframe-1"?
I want to customize the contents with some javascript such as onClick event
The code below results in the error "Uncaught DOMException: Blocked a frame with origin "" from accessing a cross-origin frame." Code:
let read_book_iframe = document.getElementById("read-book-iframe-1");
let element= read_book_iframe.contentWindow.document.querySelector('div');
|
|
|
|
|
|
#2 |
|
creator of calibre
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 45,615
Karma: 28549044
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
You cannot book content is rendered in a sandboxed iframe. If you want to use javascript put it in the book you are reading.
|
|
|
|
| Advert | |
|
|
![]() |
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| How to tag books as "to be read" "reading" "read" | Xwang | Library Management | 17 | 04-24-2021 03:41 PM |
| Pressing "Restore Defaults" under "Book Details" wipes all "Look & Feel" settings. | MarjaE | Library Management | 1 | 03-30-2021 12:46 PM |
| Can't access the library "Book" in T65s | giotti | Boyue | 4 | 01-09-2020 03:05 PM |
| Touch How transfer "Books Read" and "Hours Read" data | Abrakadabra77 | Kobo Reader | 5 | 02-16-2015 04:30 AM |
| "E-book access not so equal" from the Daily Illini | Nate the great | News | 1 | 12-11-2009 02:16 PM |