Register Guidelines E-Books Search Today's Posts Mark Forums Read

Go Back   MobileRead Forums > E-Book Formats > ePub

Notices

Reply
 
Thread Tools Search this Thread
Old 06-21-2018, 06:14 AM   #1
soparch
Enthusiast
soparch began at the beginning.
 
Posts: 28
Karma: 10
Join Date: Jun 2010
Device: none
equivalents to ibooks fixed layout audio read-aloud buttons

I am trying to add some play and pause buttons for audio to a fixed layout book (without extra javascript files). I have sorted it in ibooks with their -ibooks-media-overlay-enabled overlays but I cannot seem to manage it for other epub readers. I managed to get the "Play" button to work but this then disabled the highlighting of the text.
So ideally I would like it to work exactly as per ibooks i.e. the text highlights in time with the audio book and the reader can stop and start the text by clicking on the buttons on the page. (I know most devices have their own versions but the authors want some buttons on the page)

This is what I have at the moment - if someone could please help me I would be extremely grateful.
CSS file
.-epub-media-overlay-active { color:red; }
.buttons-rw { position: absolute; top: 1180px; left: 580px; font-size: 40px; font-family: "Times New Roman"; }
button.play { color: white; background: green; border: 4px solid black; left: 0; padding: 10px; border-radius: 60px 0 0 60px; -webkit-border-radius: 60px 0 0 60px; }
button.stop { color: white; background: red; border: 4px solid black; top: 0px; left: 65px; padding: 10px; border-radius: 0px 60px 60px 0px; -webkit-border-radius: 0px 60px 60px 0px; }

page
<audio id="page1.mp3" src="../Audio/page1.mp3"></audio>
<div class="buttons-rw"><button class="play" type="button" value="Play" onclick="document.getElementById('page1.mp3').play ()">Play</button><button class="stop" type="button" value="Stop" onclick="document.getElementById('xMorocco_Sting.m p3').pause()">Stop</button></div>

Thanks in advance
Soparch
soparch is offline   Reply With Quote
Old 06-22-2018, 11:22 PM   #2
Hitch
Bookmaker & Cat Slave
Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.
 
Hitch's Avatar
 
Posts: 11,447
Karma: 157030631
Join Date: Apr 2010
Location: Phoenix, AZ
Device: K2, iPad, KFire, PPW, Voyage, NookColor. 2 Droid, Oasis, Boox Note2
Quote:
Originally Posted by soparch View Post
I am trying to add some play and pause buttons for audio to a fixed layout book (without extra javascript files). I have sorted it in ibooks with their -ibooks-media-overlay-enabled overlays but I cannot seem to manage it for other epub readers. I managed to get the "Play" button to work but this then disabled the highlighting of the text.
So ideally I would like it to work exactly as per ibooks i.e. the text highlights in time with the audio book and the reader can stop and start the text by clicking on the buttons on the page. (I know most devices have their own versions but the authors want some buttons on the page)

This is what I have at the moment - if someone could please help me I would be extremely grateful.
CSS file
.-epub-media-overlay-active { color:red; }
.buttons-rw { position: absolute; top: 1180px; left: 580px; font-size: 40px; font-family: "Times New Roman"; }
button.play { color: white; background: green; border: 4px solid black; left: 0; padding: 10px; border-radius: 60px 0 0 60px; -webkit-border-radius: 60px 0 0 60px; }
button.stop { color: white; background: red; border: 4px solid black; top: 0px; left: 65px; padding: 10px; border-radius: 0px 60px 60px 0px; -webkit-border-radius: 0px 60px 60px 0px; }

page
<audio id="page1.mp3" src="../Audio/page1.mp3"></audio>
<div class="buttons-rw"><button class="play" type="button" value="Play" onclick="document.getElementById('page1.mp3').play ()">Play</button><button class="stop" type="button" value="Stop" onclick="document.getElementById('xMorocco_Sting.m p3').pause()">Stop</button></div>

Thanks in advance
Soparch
May I ask, where is it that the authors think this is going to be played? What vendor? Other than KoboBooks, I mean?

Hitch
Hitch is offline   Reply With Quote
Advert
Old 06-25-2018, 03:48 AM   #3
soparch
Enthusiast
soparch began at the beginning.
 
Posts: 28
Karma: 10
Join Date: Jun 2010
Device: none
I think the authors also want to sell it on their website so it can be viewed using other apps apart from ibooks
soparch is offline   Reply With Quote
Old 06-25-2018, 09:27 AM   #4
Hitch
Bookmaker & Cat Slave
Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.
 
Hitch's Avatar
 
Posts: 11,447
Karma: 157030631
Join Date: Apr 2010
Location: Phoenix, AZ
Device: K2, iPad, KFire, PPW, Voyage, NookColor. 2 Droid, Oasis, Boox Note2
Quote:
Originally Posted by soparch View Post
I think the authors also want to sell it on their website so it can be viewed using other apps apart from ibooks
Well...that's all well and good, but without knowing which "other apps" they're talking about, nobody can help you. In terms of physical devices, only iBooks has a viable read-along functionality, which, IIRC, is emulated in KoboBooks, in the higher-end devices. Nooks don't do this, nor do Kindles, Sony, et al.

So, by "other apps" do they mean, say, Readium, or Aazardi? Or...? Readalong functionality isn't some built-in thing, that works everywhere. It's device and app-specific, and you have to know what type of scripting is available to you, in order to write code that will work.

Speaking bluntly, this sounds like a case for client education. And with all due respect, you don't seem to be up to speed on the world of eReaders, either, if you're even entertaining this idea from them, or haven't already explained to them that they went through all this, paid all this, for "readalong" functionality that pretty much only exists in a single place.

Hitch
Hitch is offline   Reply With Quote
Old 06-25-2018, 05:27 PM   #5
dwig
Wizard
dwig ought to be getting tired of karma fortunes by now.dwig ought to be getting tired of karma fortunes by now.dwig ought to be getting tired of karma fortunes by now.dwig ought to be getting tired of karma fortunes by now.dwig ought to be getting tired of karma fortunes by now.dwig ought to be getting tired of karma fortunes by now.dwig ought to be getting tired of karma fortunes by now.dwig ought to be getting tired of karma fortunes by now.dwig ought to be getting tired of karma fortunes by now.dwig ought to be getting tired of karma fortunes by now.dwig ought to be getting tired of karma fortunes by now.
 
dwig's Avatar
 
Posts: 1,613
Karma: 6718479
Join Date: Dec 2004
Location: Paradise (Key West, FL)
Device: Current:Surface Go & Kindle 3 - Retired: DellV8p, Clie UX50, ...
Quote:
Originally Posted by soparch View Post
... I have sorted it in ibooks with their -ibooks-media-overlay-enabled overlays but I cannot seem to manage it for other epub readers. ...
Ah, there's the rub...

As an addenda to Hitch's excellent response, it should be noted that iBooks is not a true ePub reader. While it can read standard ePub books, it is primarily built around Apple's proprietary extension to the ePub spec.

It's not a matter of making things work is "other ePub readers", but instead it is a matter of emulating iBooks' proprietary functions in standard ePub books, something that is not always possible.
dwig is offline   Reply With Quote
Advert
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Fixing fixed layout Epub for Ibooks ? Firebrand007 ePub 2 12-15-2014 01:41 PM
Ibooks, Epub3 and fixed layout overflow? fdeandao ePub 5 05-15-2014 11:30 PM
fixed layout text display on iBooks rnuss ePub 3 03-24-2014 06:26 AM
Unusual audio problem in fixed-layout EPUB sgirsberger ePub 1 10-11-2013 06:04 PM
Fixed Layout w/ Audio Confusion RJamesW Workshop 1 07-16-2013 01:41 AM


All times are GMT -4. The time now is 08:52 PM.


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