Thread: I need help!!!
View Single Post
Old 11-02-2010, 02:31 PM   #2
Jellby
frumious Bandersnatch
Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.
 
Jellby's Avatar
 
Posts: 7,555
Karma: 19500001
Join Date: Jan 2008
Location: Spaniard in Sweden
Device: Cybook Orizon, Kobo Aura
I would actually prefer the former markup, as it lets you control how each line wraps in narrow screens (typically, I'd have some largish negative indent; ideally, the wrapped part would be right-aligned)

I see you have spaces before the <p>, is that the case in every stanza and only inside stanzas?, then you could try something like:

search: "^ <p>(.*)</p>"
replace: " \1<br/>"

Otherwise, it gets complicated, I'd probably proceed stepwise: search for "<div class="stanza">, whatever, </p>\n<p>, whatever, </div>", where "whatever" stands for "any character, including newlines, multiple times, as few as possible", and repeat as needed.
Jellby is offline   Reply With Quote