Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Formats > ePub

Notices

Reply
 
Thread Tools Search this Thread
Old 08-09-2024, 03:31 PM   #1
Daniele Giampà
Junior Member
Daniele Giampà began at the beginning.
 
Daniele Giampà's Avatar
 
Posts: 9
Karma: 10
Join Date: Jan 2024
Location: London
Device: none
EPUB container

Hello

I have a question about a video that I embedded in the introduction of my EPUB3 ebook "Tape Mark 3": https://edgedpub.com/sample_work_6.php

The EPUB-Checker shows me 2 errors (see attachment) that are related to the video on line 173 of the file introduction.xhtml.

<div>
<iframe width="560" height="315" src="https://www.youtube.com/embed/8i7uFCK7G0o" title="YouTube video player" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share" allowfullscreen=""></iframe>
</div>

I looked for explanations about Error RSC-006 regarding the EPUB container.
On the web page Anatomy of an EPU3 file I read that the file container.xml is in the folder META-INF.

I have 3 questions:

1) Is there a problem with the iframe?

2) What does it mean that I have to "locate the resource in the EPUB container"?

3) How do I insert the video in the manifest? How do I write this line of code for the video?

<item id="..." href="..." media-type="video/..."/>



Thank you for your help.
Daniele
Attached Thumbnails
Click image for larger version

Name:	video.png
Views:	29
Size:	469.3 KB
ID:	210059   Click image for larger version

Name:	container.png
Views:	29
Size:	273.3 KB
ID:	210061  
Daniele Giampà is offline   Reply With Quote
Old 08-09-2024, 04:31 PM   #2
Quoth
the rook, bossing Never.
Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.
 
Quoth's Avatar
 
Posts: 12,143
Karma: 89201339
Join Date: Jun 2017
Location: Ireland
Device: All 4 Kinds: epub eink, Kindle, android eink, NxtPaper11
1) Maybe. If the video was in the ebook, you'd not need an iFrame.
2) The video is a link to YouTube. You do that on a Website. The video needs to be in the ebook, (which makes it interactive media and not really an ebook)
3) You need a video file, not a link, so, no href except to a file actually in the ebook.

You have not embedded a video in an ebook. You have used epub3 as if it's a web-page. You have only put a link to a video. You need the actual video file.

An ebook might have a link to a publisher's web site or something. But the actual ebook, entire, has to work on its own without the internet, otherwise you might as well offer a link to a website with the iframe and whatever else is in the ebook.

Most distributors of ebooks and ereaders and ereader apps won't do video.

You can do loads of stuff with epub3, but not all of it makes sense as an ebook.

Putting a link to a video isn't embedding a video. It's embedding a link:
viz:


The above is your link embedded. The video isn't embedded on MobileRead but is still on YouTube.

Last edited by Quoth; 08-09-2024 at 04:34 PM.
Quoth is offline   Reply With Quote
Advert
Old 08-09-2024, 04:54 PM   #3
Quoth
the rook, bossing Never.
Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.
 
Quoth's Avatar
 
Posts: 12,143
Karma: 89201339
Join Date: Jun 2017
Location: Ireland
Device: All 4 Kinds: epub eink, Kindle, android eink, NxtPaper11
Epub container is the zip file with all the resources.

Rename an epub to zip and an archive program will show all the files. However better to use Sigil to craft an epub3, if that's what you really need, rather than try to assemble the parts into an archive.
Quoth is offline   Reply With Quote
Old Yesterday, 06:06 PM   #4
Daniele Giampà
Junior Member
Daniele Giampà began at the beginning.
 
Daniele Giampà's Avatar
 
Posts: 9
Karma: 10
Join Date: Jan 2024
Location: London
Device: none
Many thanks, Quoth.

The initial idea was to link the EPUB with an external page. Now I will think about what I want to do with the video and then choose an option.
Daniele Giampà is offline   Reply With Quote
Old Yesterday, 06:42 PM   #5
KevinH
Sigil Developer
KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.
 
Posts: 7,909
Karma: 5449552
Join Date: Nov 2009
Device: many
If it is an epub3, and if the remote resource is an actual video and not a link to a web page with the video embedded, simply go to the opf manifest for this file and add "remote-resources" under properties. This tells the ereader that that specific xhtml page accesses a remote resource.

Then add a manifest entry to point to the remote resource.

Something like the following example:

<item id="content_001" href="content_001.xhtml" media-type="application/xhtml+xml" properties="remote-resources"/>

<item id="outside-resource" href="https://www.myserver.com/myvideo.mp4" media-type="video/mp4" />

But you must use a video tag in your xhtml and not an iframe as iframe's are viewed as a security issue by the epub3 spec.

If the video is small enough, just hosting it inside the epub will work just fine.

Last edited by KevinH; Yesterday at 09:33 PM.
KevinH is offline   Reply With Quote
Advert
Old Today, 04:11 AM   #6
Quoth
the rook, bossing Never.
Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.
 
Quoth's Avatar
 
Posts: 12,143
Karma: 89201339
Join Date: Jun 2017
Location: Ireland
Device: All 4 Kinds: epub eink, Kindle, android eink, NxtPaper11
Quote:
Originally Posted by KevinH View Post
If it is an epub3, and if the remote resource is an actual video and not a link to a web page with the video embedded, simply go to the opf manifest for this file and add "remote-resources" under properties. This tells the ereader that that specific xhtml page accesses a remote resource.

Then add a manifest entry to point to the remote resource.
Yes, that works but is pointless. What you have is useless without the internet and a decent webpage will work better, without having to find an epub3 app that does multimedia.

There are many things that work in epub3 that simply use epub3 as a kind of app framework for an epub3 app (player), but that doesn't mean that they are genuine ebooks that can be distributed as ebooks.
A PDF is an electronic document, not an ebook. Simulating that in epub3 or kfx etc doesn't make a real ebook (reflowable), but just something that on Amazon doesn't use Adobe DRM.
You can make a perfectly working interactive multimedia presentation with epub3, but it's not an ebook, even though epub3 can be used to produce perfect ebooks with extra sematics for TTS compared to epub2, or "prettier" and more complex layout.

So epub3 allows broadly 4 kinds of things:
  1. An ebook that still works fine on an epub2 renderer.
  2. An ebook that only works (or properly works) on an epub3 renderer.
  3. A fixed layout mimicking what a PDF does. Electronic, but not an ebook.
  4. An interactive and/or multimedia experience. This is not an ebook. Available since later 1980s even on DOS. Frameworks for iOS/Android, but the epub3 is easier to learn. Some good programs to author since win 3.1 (not Powerpoint), oddly fewer now on Win1x as replaced by browser based authoring.

#1 will redistribute on all ebook platforms
#2 will redistribute on some ebook plaforms
#3 will redistribute on Amazon as a Kindle ebook, but of eink Kindles, only to the Scribe.
#4 will not redistribute as an ebook. It needs a compliant epub3 app.

Anything with major or important content online (i.e. anything more than link to publisher or other books) is better as either a web page or an app that needs the internet. It's not a ebook and no-one will distribute it as an ebook. It's also useless without the internet.
Quoth is offline   Reply With Quote
Old Today, 04:20 AM   #7
Quoth
the rook, bossing Never.
Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.
 
Quoth's Avatar
 
Posts: 12,143
Karma: 89201339
Join Date: Jun 2017
Location: Ireland
Device: All 4 Kinds: epub eink, Kindle, android eink, NxtPaper11
Quote:
Originally Posted by KevinH View Post
But you must use a video tag in your xhtml and not an iframe as iframe's are viewed as a security issue by the epub3 spec.
I banned use of iframe in company I worked in over 20 years ago. The idiot was using it to reuse content from someone else's site in our web site.

They are also used to serve adverts which later can server malware.

Quote:
Originally Posted by KevinH View Post
If the video is small enough, just hosting it inside the epub will work just fine.
Which is what I suggested. That way it works forever. Though it's still not a real ebook.
It's storing, not hosting. It's an epub3, not a web site.

Any static distribution / app that needs a remote resource is better done as an app or best is as a web site. What happens if YouTube (or other provider) takes down the video? What happens if the user loses the internet connection?
Quoth is offline   Reply With Quote
Old Today, 10:36 AM   #8
KevinH
Sigil Developer
KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.
 
Posts: 7,909
Karma: 5449552
Join Date: Nov 2009
Device: many
You and I will disagree on that. An epub3 with audio and/or video is a real ebook and works with decent epub3 ereaders which now are common and are easy to find.

Readium, Thorium, iBooks, etc, to name just a few.

IMHO, you are too fixated in old epub2. The world has moved on from that.
KevinH is offline   Reply With Quote
Old Today, 12:55 PM   #9
Quoth
the rook, bossing Never.
Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.
 
Quoth's Avatar
 
Posts: 12,143
Karma: 89201339
Join Date: Jun 2017
Location: Ireland
Device: All 4 Kinds: epub eink, Kindle, android eink, NxtPaper11
Quote:
Originally Posted by KevinH View Post
You and I will disagree on that. An epub3 with audio and/or video is a real ebook and works with decent epub3 ereaders which now are common and are easy to find.

Readium, Thorium, iBooks, etc, to name just a few.

IMHO, you are too fixated in old epub2. The world has moved on from that.
It's a real epub3. But not a book as we know it. Humpty Dumpty.

It's not about epub2 vs epub3. It's about what constitutes an ebook.

We've had ebooks AND multimedia for about 40 years. Using epub3 as the spec or tool to make a multimedia / interactive title doesn't mean it's an ebook.

PDFs, Fixed layout Kindle, Fixed layout epub3 and multimedia (built wiith pure epub3 or any other way) are not ebooks.

Web pages are also not ebooks, though you can display an ebook or a PDF in a browser. I use Okular for PDFs and sometimes ebooks. I only use the browser for web pages.

There are loads of programs and apps that can render or play things in totally different categories.

Readium, Thorium, iBooks, etc can display things that are not ebooks. So can Pocketbook app and it has aspects of PDF reading/viewing better than Xodo, thought of as a PDF viewer. Xodo is also and image viewer, but that doesn't mean those images are PDFs.

Epub3 certainly has some improved semantics for real ebooks that are read by TTS, but not everything you can create with epub3 is a real ebook.

See also HTML. Not everything made with HTML is a webpage.

Java can be used to make a desktop program or be part of the server side of a website.

The more powerful a tool the more things can be made.

Postscript is useful, but not all postscript is in PDFs and a PDF might have no postscript.
PDFs have been extended with javascript to be used as interactive forms which is stupid compared to proper website. A stupid decision and no use for the original purpose. I have Javascript disabled by default in all PDF viewers for about 20+ years, and PDF viewing disabled in browsers since it was enabled.

Sure, do interactive multimedia using epub3. But call it what it is, Interactive Multimedia. A thing that has existed a decade or more before mobi or the precursor of epub2 (1998-1999 OEBPS). The epub3 is version 3 of OEBPS and only became a multimedia authoring tool because W3C took over epub2. A natural thing for them to do.
Quoth is offline   Reply With Quote
Old Today, 04:38 PM   #10
KevinH
Sigil Developer
KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.
 
Posts: 7,909
Karma: 5449552
Join Date: Nov 2009
Device: many
That is pure semantics. An e-book by almost any modern definition can include audio and video and even limited javascript for interactivity. Thus the "e-". Your definition and my definition of "e-book" differ but yours is out of date in my opinion.

But to each their own.
KevinH is offline   Reply With Quote
Old Today, 05:14 PM   #11
JSWolf
Resident Curmudgeon
JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.
 
JSWolf's Avatar
 
Posts: 75,422
Karma: 133807966
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3
Quote:
Originally Posted by Daniele Giampà View Post
Many thanks, Quoth.

The initial idea was to link the EPUB with an external page. Now I will think about what I want to do with the video and then choose an option.
Do you have permission to use this video?
JSWolf is offline   Reply With Quote
Old Today, 05:15 PM   #12
DiapDealer
Grand Sorcerer
DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.
 
DiapDealer's Avatar
 
Posts: 27,747
Karma: 197700000
Join Date: Jan 2010
Device: Nexus 7, Kindle Fire HD
Quote:
Originally Posted by JSWolf View Post
Do you have permission to use this video?
No reason to assume they don't. Stop fishing.
DiapDealer is offline   Reply With Quote
Old Today, 05:21 PM   #13
JSWolf
Resident Curmudgeon
JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.
 
JSWolf's Avatar
 
Posts: 75,422
Karma: 133807966
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3
Quote:
Originally Posted by KevinH View Post
That is pure semantics. An e-book by almost any modern definition can include audio and video and even limited javascript for interactivity. Thus the "e-". Your definition and my definition of "e-book" differ but yours is out of date in my opinion.

But to each their own.
IMHO, multimedia should never have been allowed in ePub 3. That's Apple buying the standard board.
JSWolf is offline   Reply With Quote
Old Today, 05:45 PM   #14
DNSB
Bibliophagist
DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.
 
DNSB's Avatar
 
Posts: 38,358
Karma: 152278604
Join Date: Jul 2010
Location: Vancouver
Device: Kobo Sage, Libra Colour, Lenovo M8 FHD, Paperwhite 4, Tolino epos
Hmmm... when we used Youtube videos in coursework, the following is a much shorter version of the verbiage the district lawyers came up with:

Quote:
Is it legal to share a YouTube video with my students?

It is completely legal to use YouTube videos in your course (either shared by link or embedded) because the licensing that YouTube offers makes this possible. YouTube videos carry either the YouTube Standard License, or a Creative Commons BY CC-BY License. In order to use content from YouTube legally (films with either the YouTube Standard License or the CC-BY License), the licenses require users to give attribution to the creator of the work/copyright owner. The primary difference between the YouTube Standard License and the Creative Commons License is that you could actually modify or adapt a YouTube video with a Creative Commons License. YouTube videos are fine to use and share either by linking or embedding, but when using YouTube it's a good idea to make sure that the content itself is not infringing.
DNSB is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Extracting and repacking epub (as zip) shows missing container.xml file bendtherules Editor 4 10-27-2021 01:55 PM
container.mi and unicode jackie_w Development 7 05-27-2018 10:49 AM
Recreating Container.xhtml SigilBear Sigil 42 06-27-2017 05:32 PM
container.xml problems SigilBear Sigil 4 06-11-2017 09:43 PM
Container methods, various scenarios jackie_w Development 15 11-09-2015 02:32 PM


All times are GMT -4. The time now is 07:49 PM.


MobileRead.com is a privately owned, operated and funded community.