View Single Post
Old 05-26-2012, 10:24 AM   #40
theducks
Well trained by Cats
theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.
 
theducks's Avatar
 
Posts: 31,123
Karma: 60406498
Join Date: Aug 2009
Location: The Central Coast of California
Device: Kobo Libra2,Kobo Aura2v1, K4NT(Fixed: New Bat.), Galaxy Tab A
Quote:
Originally Posted by JSWolf View Post
Let me make this simple and show you how it's done and how to do it your way easily.

I'll start with chapter headers using <p class="para">Chapter One</p>. We change that to <h2 class="para">Chapter One</h2>. With me so far? Good. Now you've fixed all the chapter titles to be <h2 class="para">chaptertitle</h2> and that's good except you don't want the class there. Now the easy part begins. All you do is search <h2 class="para"> and replace it with <h2>. See, easy. All it takes is one extra simple step and it works and it gets the job done.

Did you follow that?
I do it all in 1 pass: <p class="para">Chapter One</p> and create a unique class just in case I want to style it (now or later). (The bloat, is tiny for chapter heads.

Code:
<p class="para">Chapter (.+)</p>
Code:
<h2 class="chapno">Chapter \1</h2>
Code:
.chapno {display: block}
theducks is offline   Reply With Quote