View Single Post
Old 02-20-2014, 08:57 AM   #2
RbnJrg
Wizard
RbnJrg ought to be getting tired of karma fortunes by now.RbnJrg ought to be getting tired of karma fortunes by now.RbnJrg ought to be getting tired of karma fortunes by now.RbnJrg ought to be getting tired of karma fortunes by now.RbnJrg ought to be getting tired of karma fortunes by now.RbnJrg ought to be getting tired of karma fortunes by now.RbnJrg ought to be getting tired of karma fortunes by now.RbnJrg ought to be getting tired of karma fortunes by now.RbnJrg ought to be getting tired of karma fortunes by now.RbnJrg ought to be getting tired of karma fortunes by now.RbnJrg ought to be getting tired of karma fortunes by now.
 
Posts: 1,528
Karma: 6613969
Join Date: Mar 2013
Location: Rosario - Santa Fe - Argentina
Device: Kindle 4 NT
Quote:
Originally Posted by mrmikel View Post
I have been trying to replace tables in my epubs with divs and css.

As with tables, when the text size is increased, things get out of line with each other. In tables it seems a little more graceful a failure.

Is there any way to make the following div in a table track with the preceding one?

This is what I am doing:
CSS
.row {
width: 100%;
}
.col1{
float: left;
min-height: 1px;
width: 75%;
text-align: left}
.col2, .col3 {
float: right;
min-height: 1px;
width: 25%;
text-align: right; }
.clear {
border: none;
clear: both;

}
HTML
<div class='row'>
<div class='col1'>
Ordnance and ordnance stores
</div>
<div class='col2'>
$45,000,000 </div>
</div>
I'm not undestand very well what you want to do (my english is very bad). But if you want to add new entries to your "fake" table (made of <div> selectors) then I think the easiest way is:

Code:
<div class='row'>
  <div class='col1'>
    Entry 1 - First Column<br />
    Entry 2 - First Column<br />
    Entry 3 - First Column<br />
    Etc...
  </div>
  <div class='col2'>
    Entry 1 - Second Column<br />
    Entry 2 - Second Column<br />
    Entry 3 - Second Column<br />
    Etc...
  </div>
</div>
Regards
Rubén
RbnJrg is offline   Reply With Quote