Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Software > Sigil

Notices

Reply
 
Thread Tools Search this Thread
Old 09-12-2012, 09:35 AM   #1
Oldpilot
Groupie
Oldpilot plays well with othersOldpilot plays well with othersOldpilot plays well with othersOldpilot plays well with othersOldpilot plays well with othersOldpilot plays well with othersOldpilot plays well with othersOldpilot plays well with othersOldpilot plays well with othersOldpilot plays well with othersOldpilot plays well with others
 
Posts: 184
Karma: 2572
Join Date: Aug 2010
Device: Kindle
problem with added characters

In my html file, I have the following line:

<span class="underline">action</span> and <span class="underline">decision</span>

But when I open the html file in Sigil, I see this:

<span class="underline&gt;action&lt;/span&gt; and &lt;span class=" underline="">decision</span>

As a result, epub validator makes this complaint:

attribute "underline" not allowed here; expected attribute "dir", "id", "style", "title" or "xml:lang"

So, two questions:

1. Why do you suppose Sigil makes such radical changes in the text, accepting some instances of < and > but changing others, and again adding a space and a straight quote which seem to have created invalid epub?

2. Am I correct in thinking that epub validator is complaining about the space and the apparent extra " in the second instance, to wit: " underline="">

There are many instances of span="underline" in the document, but only three errors relating to the word "underline".

Thanks!
Oldpilot is offline   Reply With Quote
Old 09-12-2012, 10:03 AM   #2
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: 29,785
Karma: 54830978
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 Oldpilot View Post
In my html file, I have the following line:

<span class="underline">action</span> and <span class="underline">decision</span>

But when I open the html file in Sigil, I see this:

<span class="underline&gt;action&lt;/span&gt; and &lt;span class=" underline="">decision</span>

As a result, epub validator makes this complaint:

attribute "underline" not allowed here; expected attribute "dir", "id", "style", "title" or "xml:lang"

So, two questions:

1. Why do you suppose Sigil makes such radical changes in the text, accepting some instances of < and > but changing others, and again adding a space and a straight quote which seem to have created invalid epub?

2. Am I correct in thinking that epub validator is complaining about the space and the apparent extra " in the second instance, to wit: " underline="">

There are many instances of span="underline" in the document, but only three errors relating to the word "underline".

Thanks!
In all cases I have seen Tags changed to entities, there has been something malformed in the Tag pair and it got treated as/converted to text.

In this case, I think it is the uppercase-bracketed [B]

You would be best served using the newer way of doing bold, using a selector <p class="bold">... </p>
and in the CSS
.bold { font-weight: bold; }

Last edited by theducks; 09-12-2012 at 07:31 PM. Reason: Ooops! the braket was MR's,strike all
theducks is offline   Reply With Quote
Old 09-12-2012, 12:21 PM   #3
mmat1
Berti
mmat1 ought to be getting tired of karma fortunes by now.mmat1 ought to be getting tired of karma fortunes by now.mmat1 ought to be getting tired of karma fortunes by now.mmat1 ought to be getting tired of karma fortunes by now.mmat1 ought to be getting tired of karma fortunes by now.mmat1 ought to be getting tired of karma fortunes by now.mmat1 ought to be getting tired of karma fortunes by now.mmat1 ought to be getting tired of karma fortunes by now.mmat1 ought to be getting tired of karma fortunes by now.mmat1 ought to be getting tired of karma fortunes by now.mmat1 ought to be getting tired of karma fortunes by now.
 
mmat1's Avatar
 
Posts: 1,196
Karma: 4985964
Join Date: Jan 2012
Location: Zischebattem
Device: Acer Lumiread
Quote:
Originally Posted by Oldpilot View Post
1. Why do you suppose Sigil makes such radical changes in the text, accepting some instances of < and > but changing others, and again adding a space and a straight quote which seem to have created invalid epub?

2. Am I correct in thinking that epub validator is complaining about the space and the apparent extra " in the second instance, to wit: " underline="">
1. You probably missed the Quote between the first underline and the >

2. Epub-Validator takes the second underline as attribute-name, not as value and probably does not see the missing quote before the second underline. Don't think too much about it...
mmat1 is offline   Reply With Quote
Old 09-12-2012, 07:17 PM   #4
Oldpilot
Groupie
Oldpilot plays well with othersOldpilot plays well with othersOldpilot plays well with othersOldpilot plays well with othersOldpilot plays well with othersOldpilot plays well with othersOldpilot plays well with othersOldpilot plays well with othersOldpilot plays well with othersOldpilot plays well with othersOldpilot plays well with others
 
Posts: 184
Karma: 2572
Join Date: Aug 2010
Device: Kindle
You would be best served using the newer way of doing bold,

But there is no bold in that set of underlinings! Are you saying that span class=underline should be p class="underline"? I should use paragraph tags within a sentence? Surely that will create a new line?

And

You probably missed the Quote between the first underline and the >


I don't see any missing quote. It reads: <span class="underline">. That's pasted from the original html file.

Perhaps I should have said that the html validates without a problem.

I suppose I could simply use italics, though that's not true to the original.
Oldpilot is offline   Reply With Quote
Old 09-12-2012, 07:30 PM   #5
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: 29,785
Karma: 54830978
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 Oldpilot View Post
You would be best served using the newer way of doing bold,

But there is no bold in that set of underlinings! Are you saying that span class=underline should be p class="underline"? I should use paragraph tags within a sentence? Surely that will create a new line?

And

You probably missed the Quote between the first underline and the >


I don't see any missing quote. It reads: <span class="underline">. That's pasted from the original html file.

Perhaps I should have said that the html validates without a problem.

I suppose I could simply use italics, though that's not true to the original.
I went back and corrected my post almost as soon as I posted , just not enough
theducks is offline   Reply With Quote
Old 09-12-2012, 07:35 PM   #6
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: 29,785
Karma: 54830978
Join Date: Aug 2009
Location: The Central Coast of California
Device: Kobo Libra2,Kobo Aura2v1, K4NT(Fixed: New Bat.), Galaxy Tab A
All I can think of: there was a mismatch in the closing </span> or different quote marks were used. something unbalanced the span
theducks is offline   Reply With Quote
Old 09-12-2012, 07:39 PM   #7
DiapDealer
Grand Sorcerer
DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.
 
DiapDealer's Avatar
 
Posts: 27,547
Karma: 193191846
Join Date: Jan 2010
Device: Nexus 7, Kindle Fire HD
I've never seen Sigil turn a opening/closing tag into an entity on well-formed (x)html. I'm not saying yours isn't/wasn't well-formed ... I'm just saying that out of the 100 of thousands of lines of (x)html code I've run into/through Sigil ... every single instance of &gt; or &lt; has been my fault. 100%. Either I purposely entered the entities because I wanted them there, or I screwed up the code and Sigil failed to correctly guess what I did wrong.

I've tried importing, pasting, opening that line of html you posted and I just can't get Sigil to screw it up. The only way I can get Sigil to reproduce your problem is by forgetting one of the attribute quotes.

Last edited by DiapDealer; 09-12-2012 at 07:41 PM.
DiapDealer is offline   Reply With Quote
Old 09-13-2012, 03:57 AM   #8
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,515
Karma: 18512745
Join Date: Jan 2008
Location: Spaniard in Sweden
Device: Cybook Orizon, Kobo Aura
Maybe some of the quotes are curly/directional (“”) instead of straight? Delete and write them again and see if that helps.
Jellby is offline   Reply With Quote
Old 09-13-2012, 06:35 AM   #9
ghostyjack
Guru
ghostyjack ought to be getting tired of karma fortunes by now.ghostyjack ought to be getting tired of karma fortunes by now.ghostyjack ought to be getting tired of karma fortunes by now.ghostyjack ought to be getting tired of karma fortunes by now.ghostyjack ought to be getting tired of karma fortunes by now.ghostyjack ought to be getting tired of karma fortunes by now.ghostyjack ought to be getting tired of karma fortunes by now.ghostyjack ought to be getting tired of karma fortunes by now.ghostyjack ought to be getting tired of karma fortunes by now.ghostyjack ought to be getting tired of karma fortunes by now.ghostyjack ought to be getting tired of karma fortunes by now.
 
ghostyjack's Avatar
 
Posts: 718
Karma: 1085610
Join Date: Mar 2009
Location: Bristol, England
Device: PRS-T1, 1825PT, Galaxy Tab, One X, TF700T, Aura HD, Nexus 7
I've had this happen to me a couple of times with the 0.6.0 beta's. I never could figure out what caused it as looking at my master copies of the files that had this, they looks perfectly fine. Certainly the quotes were all straight.

This seemed to be a random occurance, I could never replicate it. It just seemed to happen.
ghostyjack is offline   Reply With Quote
Old 09-13-2012, 12:27 PM   #10
mmat1
Berti
mmat1 ought to be getting tired of karma fortunes by now.mmat1 ought to be getting tired of karma fortunes by now.mmat1 ought to be getting tired of karma fortunes by now.mmat1 ought to be getting tired of karma fortunes by now.mmat1 ought to be getting tired of karma fortunes by now.mmat1 ought to be getting tired of karma fortunes by now.mmat1 ought to be getting tired of karma fortunes by now.mmat1 ought to be getting tired of karma fortunes by now.mmat1 ought to be getting tired of karma fortunes by now.mmat1 ought to be getting tired of karma fortunes by now.mmat1 ought to be getting tired of karma fortunes by now.
 
mmat1's Avatar
 
Posts: 1,196
Karma: 4985964
Join Date: Jan 2012
Location: Zischebattem
Device: Acer Lumiread
Quote:
Originally Posted by Oldpilot View Post
You probably missed the Quote between the first underline and the >

I don't see any missing quote. It reads: <span class="underline">. That's pasted from the original html file.
Sorry, but: There is no error now in your posting, but the error was there when you pasted it to your epub (or the quote was accidentally deleted afterwards).

Just try it out: turn well-fornmed check off, paste your code to a blank xhtml, remove that quote, save and close the file and open it again and look what sigil did with your code.
mmat1 is offline   Reply With Quote
Old 09-16-2012, 08:22 AM   #11
Oldpilot
Groupie
Oldpilot plays well with othersOldpilot plays well with othersOldpilot plays well with othersOldpilot plays well with othersOldpilot plays well with othersOldpilot plays well with othersOldpilot plays well with othersOldpilot plays well with othersOldpilot plays well with othersOldpilot plays well with othersOldpilot plays well with others
 
Posts: 184
Karma: 2572
Join Date: Aug 2010
Device: Kindle
The problem seems to have been my using underline when I should have used u. The file now validates.

I shouldn't have confused the matter by asking about the messed-up characters. Sorry!
Oldpilot is offline   Reply With Quote
Old 09-16-2012, 09:54 AM   #12
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: 29,785
Karma: 54830978
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 Oldpilot View Post
The problem seems to have been my using underline when I should have used u. The file now validates.

I shouldn't have confused the matter by asking about the messed-up characters. Sorry!
Code:
<span class="underline">
should not cause a validation problem.
I would expect that there would be a (at minimum):
Code:
.underline { text-decoration: underline; }
in the CSS, but Flightcrew does not fail a missing CSS selector
theducks is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Problem with Turkish Characters aeolus Kindle Formats 13 02-22-2012 07:10 AM
Pdf to epub Problem with Turkish Characters Nazimco ePub 2 01-19-2012 07:04 PM
Touch Problem handling multi-byte characters? zhhbc Kobo Reader 12 06-22-2011 09:47 AM
Creator Problem with spanish characters Darkitow Kindle Formats 1 03-25-2011 08:53 AM
Non-english characters input problem Celeblin Calibre 3 06-28-2009 02:05 PM


All times are GMT -4. The time now is 10:32 PM.


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