Q: iOS7 differently displaying images with % "height" in CSS
Hello there...
Prior to iOS7, iBooks were displying the books we are doing one way - the way we wanted-, and with iOS7 it has changed.
Particularly: before, we were setting the "height" of a <div> containing an image as a % on CSS like this:
.contenedor_foto_autor {
height:100%;
width:auto;
page-break-before:always;
page-break-inside: avoid;
text-align:center;
font-size:0.9em;
}
.foto-autor {
height:70%;
width:auto;
}
And the xhtml being:
<div class="contenedor_foto_autor">
<div class="foto_autor">
<img src="imagenes/Robert_Louis_Stevenson_1885.jpg" alt="Retrato"/>
</div>
<p><span class="letra_mayor">R</span>OBERT <span class="letra_mayor">L</span>OUIS <span class="letra_mayor">S</span>TEVENSON</p
</div>
The result of this was a picture filling the 70% of the iPad/iPhone screen height, and the text under it, as we expected.
Now, this same code results on the picture filling ALL the page and the <p> on the next page.
Any ideas, sugestions, help to understand what is happening and how to solve this -how to have the "height" set ???
Thank you!!
iBook, iOS 6.1
Posted on Oct 17, 2013 9:08 AM